exp init: timeout prompts' test

The `exp init` tests may just keep waiting on the prompts blocking tests.
The blocking of prompts is likely a failure in tests setup or a bug
in the implementation. It's hard to find out these failures or avoid it.
If they take longer than 1 second, they most likely have failed as
most of test takes 0.1 second at max.
This commit is contained in:
Saugat Pachhai (सौगात)
2021-11-22 03:27:16 +02:00
committed by Ruslan Kuprieiev
parent 46289182d2
commit bf313d92aa
2 changed files with 4 additions and 0 deletions
+3
View File
@@ -9,6 +9,9 @@ from dvc.main import main
from dvc.repo.experiments.init import init
from dvc.stage.exceptions import DuplicateStageName
# the tests may hang on prompts on failure
pytestmark = pytest.mark.timeout(1)
def test_init_simple(tmp_dir, scm, dvc, capsys):
tmp_dir.gen(