forked from p15670423/monkey
Fix unit tests (test_utils.py)
This commit is contained in:
parent
7240d60342
commit
4b733ba383
|
@ -9,18 +9,18 @@ from monkey_island.cc.environment.utils import create_secure_directory, is_windo
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
def test_path_nested(tmpdir):
|
def test_path_nested(tmpdir):
|
||||||
nested_path = "/test1/test2/test3"
|
nested_path = "test1/test2/test3"
|
||||||
path = os.path.join(tmpdir, nested_path)
|
path = os.path.join(tmpdir, nested_path)
|
||||||
yield path
|
yield path
|
||||||
try:
|
try:
|
||||||
shutil.rmtree(os.path.join(tmpdir, "/test1"))
|
shutil.rmtree(os.path.join(tmpdir, "test1"))
|
||||||
except Exception:
|
except Exception:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
def test_path(tmpdir):
|
def test_path(tmpdir):
|
||||||
test_path = "/test1"
|
test_path = "test1"
|
||||||
path = os.path.join(tmpdir, test_path)
|
path = os.path.join(tmpdir, test_path)
|
||||||
yield path
|
yield path
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in New Issue