Merge pull request #6004 from blueyed/fix-nf

cache: NFPlugin: keep known nodeids
This commit is contained in:
Daniel Hahler
2019-10-23 01:04:48 +02:00
committed by GitHub
3 changed files with 13 additions and 3 deletions

View File

@@ -982,8 +982,13 @@ class TestNewFirst:
)
testdir.tmpdir.join("test_1/test_1.py").setmtime(1)
result = testdir.runpytest("-v", "--nf")
# Running only a subset does not forget about existing ones.
result = testdir.runpytest("-v", "--nf", "test_2/test_2.py")
result.stdout.fnmatch_lines(
["*test_2/test_2.py::test_1[1*", "*test_2/test_2.py::test_1[2*"]
)
result = testdir.runpytest("-v", "--nf")
result.stdout.fnmatch_lines(
[
"*test_1/test_1.py::test_1[3*",