summaryrefslogtreecommitdiff
path: root/testing/acceptance_test.py
diff options
context:
space:
mode:
authorDaniel Hahler <git@thequod.de>2019-11-06 19:51:58 +0100
committerDaniel Hahler <git@thequod.de>2019-11-07 12:29:36 +0100
commitdd852ded705e10c85452fba1458736e71dcb06e0 (patch)
tree5d752aa8e23e98a09eed10496ea888d23d1b8c1b /testing/acceptance_test.py
parent5be3a9b5cee3ef73b627049272db5bd2e34f5026 (diff)
downloadpytest-dd852ded705e10c85452fba1458736e71dcb06e0.tar.gz
_perform_collect: remove comment about untested code
Harden one test where it is tested. All tests testing this: testing/acceptance_test.py:184(TestGeneralUsage::test_not_collectable_arguments) testing/acceptance_test.py:373(TestGeneralUsage::test_direct_addressing_notfound) testing/acceptance_test.py:403(TestGeneralUsage::test_issue134_report_error_when_collecting_member[test_fun.py::test_a]) testing/acceptance_test.py:420(TestGeneralUsage::test_report_all_failed_collections_initargs) testing/test_config.py:1309(test_config_blocked_default_plugins[python]) (via https://github.com/blueyed/pytest/pull/88)
Diffstat (limited to 'testing/acceptance_test.py')
-rw-r--r--testing/acceptance_test.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/testing/acceptance_test.py b/testing/acceptance_test.py
index 82c727fc6..578ab45eb 100644
--- a/testing/acceptance_test.py
+++ b/testing/acceptance_test.py
@@ -178,8 +178,14 @@ class TestGeneralUsage:
p1 = testdir.makepyfile("")
p2 = testdir.makefile(".pyc", "123")
result = testdir.runpytest(p1, p2)
- assert result.ret
- result.stderr.fnmatch_lines(["*ERROR: not found:*{}".format(p2.basename)])
+ assert result.ret == ExitCode.USAGE_ERROR
+ result.stderr.fnmatch_lines(
+ [
+ "ERROR: not found: {}".format(p2),
+ "(no name {!r} in any of [[][]])".format(str(p2)),
+ "",
+ ]
+ )
@pytest.mark.filterwarnings("default")
def test_better_reporting_on_conftest_load_failure(self, testdir, request):