remove flakey test
This commit is contained in:
parent
d4b6ade31a
commit
4c6e6685da
2 changed files with 4 additions and 22 deletions
|
|
@ -37,13 +37,6 @@ def tmp_recipes(tmp_path_factory: pytest.TempPathFactory) -> Path:
|
|||
return tmp_recipes_target
|
||||
|
||||
|
||||
def test_runner_runner_dict_import(tmp_recipes: Path):
|
||||
"""import from recipes dict should work, because create_runner_dict has sys.path.append"""
|
||||
|
||||
RUNNER_DICT = Coordinator.create_runner_dict(tmp_recipes)
|
||||
assert len(RUNNER_DICT.keys()) > 0
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def clear_sys_path():
|
||||
"""clear sys.path before test, restore after"""
|
||||
|
|
@ -53,14 +46,8 @@ def clear_sys_path():
|
|||
sys.path.extend(syspath_copy)
|
||||
|
||||
|
||||
def test_runner_runner_dict_import_failing(tmp_recipes: Path, clear_sys_path, monkeypatch):
|
||||
def test_runner_runner_dict_import(tmp_recipes: Path, clear_sys_path):
|
||||
"""import from recipes dict should work, because create_runner_dict has sys.path.append"""
|
||||
|
||||
monkeypatch.setattr(
|
||||
Coordinator,
|
||||
"add_to_sys",
|
||||
lambda x: x,
|
||||
)
|
||||
|
||||
with pytest.raises(ModuleNotFoundError):
|
||||
Coordinator.create_runner_dict(tmp_recipes)
|
||||
RUNNER_DICT = Coordinator.create_runner_dict(tmp_recipes)
|
||||
assert len(RUNNER_DICT.keys()) > 0
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue