Skip to content

Commit d05e24f

Browse files
committed
Make some tests use --co to avoid regressions and improved changelog
1 parent 4a18f38 commit d05e24f

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

changelog/6116.feature.rst

Lines changed: 0 additions & 1 deletion
This file was deleted.

changelog/6116.improvement.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Add ``--co`` as a synonym to ``--collect-only``.

testing/test_collection.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,7 @@ def pytest_collect_file(path, parent):
402402
)
403403
testdir.mkdir("sub")
404404
testdir.makepyfile("def test_x(): pass")
405-
result = testdir.runpytest("--collect-only")
405+
result = testdir.runpytest("--co")
406406
result.stdout.fnmatch_lines(["*MyModule*", "*test_x*"])
407407

408408
def test_pytest_collect_file_from_sister_dir(self, testdir):
@@ -433,7 +433,7 @@ def pytest_collect_file(path, parent):
433433
p = testdir.makepyfile("def test_x(): pass")
434434
p.copy(sub1.join(p.basename))
435435
p.copy(sub2.join(p.basename))
436-
result = testdir.runpytest("--collect-only")
436+
result = testdir.runpytest("--co")
437437
result.stdout.fnmatch_lines(["*MyModule1*", "*MyModule2*", "*test_x*"])
438438

439439

0 commit comments

Comments
 (0)