Lines Matching refs:testdir

9 def test_simple_unittest(testdir):  argument
10 testpath = testdir.makepyfile(
20 reprec = testdir.inline_run(testpath)
25 def test_runTest_method(testdir): argument
26 testdir.makepyfile(
39 result = testdir.runpytest("-v")
49 def test_isclasscheck_issue53(testdir): argument
50 testpath = testdir.makepyfile(
59 result = testdir.runpytest(testpath)
63 def test_setup(testdir): argument
64 testpath = testdir.makepyfile(
80 reprec = testdir.inline_run("-s", testpath)
86 def test_setUpModule(testdir): argument
87 testpath = testdir.makepyfile(
104 result = testdir.runpytest(testpath)
108 def test_setUpModule_failing_no_teardown(testdir): argument
109 testpath = testdir.makepyfile(
123 reprec = testdir.inline_run(testpath)
129 def test_new_instances(testdir): argument
130 testpath = testdir.makepyfile(
140 reprec = testdir.inline_run(testpath)
144 def test_function_item_obj_is_instance(testdir): argument
146 testdir.makeconftest(
154 testdir.makepyfile(
163 result = testdir.runpytest_inprocess()
167 def test_teardown(testdir): argument
168 testpath = testdir.makepyfile(
182 reprec = testdir.inline_run(testpath)
189 def test_teardown_issue1649(testdir): argument
197 testpath = testdir.makepyfile(
208 testdir.inline_run("-s", testpath)
214 def test_unittest_skip_issue148(testdir): argument
215 testpath = testdir.makepyfile(
231 reprec = testdir.inline_run(testpath)
235 def test_method_and_teardown_failing_reporting(testdir): argument
236 testdir.makepyfile(
246 result = testdir.runpytest("-s")
259 def test_setup_failure_is_shown(testdir): argument
260 testdir.makepyfile(
272 result = testdir.runpytest("-s")
278 def test_setup_setUpClass(testdir): argument
279 testpath = testdir.makepyfile(
299 reprec = testdir.inline_run(testpath)
303 def test_setup_class(testdir): argument
304 testpath = testdir.makepyfile(
322 reprec = testdir.inline_run(testpath)
327 def test_testcase_adderrorandfailure_defers(testdir, type): argument
328 testdir.makepyfile(
346 result = testdir.runpytest()
351 def test_testcase_custom_exception_info(testdir, type): argument
352 testdir.makepyfile(
377 result = testdir.runpytest()
387 def test_testcase_totally_incompatible_exception_info(testdir): argument
388 (item,) = testdir.getitems(
401 def test_module_level_pytestmark(testdir): argument
402 testpath = testdir.makepyfile(
412 reprec = testdir.inline_run(testpath, "-s")
423 def test_trial_testcase_runtest_not_collected(self, testdir): argument
424 testdir.makepyfile(
433 reprec = testdir.inline_run(*self.ignore_unclosed_socket_warning)
435 testdir.makepyfile(
444 reprec = testdir.inline_run(*self.ignore_unclosed_socket_warning)
447 def test_trial_exceptions_with_skips(self, testdir): argument
448 testdir.makepyfile(
482 result = testdir.runpytest("-rxs", *self.ignore_unclosed_socket_warning)
497 def test_trial_error(self, testdir): argument
498 testdir.makepyfile(
537 result = testdir.runpytest(
563 def test_trial_pdb(self, testdir): argument
564 p = testdir.makepyfile(
573 child = testdir.spawn_pytest(p)
577 def test_trial_testcase_skip_property(self, testdir): argument
578 testpath = testdir.makepyfile(
587 reprec = testdir.inline_run(testpath, "-s")
590 def test_trial_testfunction_skip_property(self, testdir): argument
591 testpath = testdir.makepyfile(
600 reprec = testdir.inline_run(testpath, "-s")
603 def test_trial_testcase_todo_property(self, testdir): argument
604 testpath = testdir.makepyfile(
613 reprec = testdir.inline_run(testpath, "-s")
616 def test_trial_testfunction_todo_property(self, testdir): argument
617 testpath = testdir.makepyfile(
626 reprec = testdir.inline_run(
632 def test_djangolike_testcase(testdir): argument
634 testdir.makepyfile(
677 result = testdir.runpytest("-s")
690 def test_unittest_not_shown_in_traceback(testdir): argument
691 testdir.makepyfile(
700 res = testdir.runpytest()
704 def test_unorderable_types(testdir): argument
705 testdir.makepyfile(
719 result = testdir.runpytest()
724 def test_unittest_typerror_traceback(testdir): argument
725 testdir.makepyfile(
733 result = testdir.runpytest()
739 def test_unittest_expected_failure_for_failing_test_is_xfail(testdir, runner): argument
740 script = testdir.makepyfile(
752 result = testdir.runpytest("-rxX")
757 result = testdir.runpython(script)
763 def test_unittest_expected_failure_for_passing_test_is_fail(testdir, runner): argument
764 script = testdir.makepyfile(
777 result = testdir.runpytest("-rxX")
782 result = testdir.runpython(script)
791 def test_unittest_setup_interaction(testdir, fix_type, stmt): argument
792 testdir.makepyfile(
819 result = testdir.runpytest()
823 def test_non_unittest_no_setupclass_support(testdir): argument
824 testpath = testdir.makepyfile(
845 reprec = testdir.inline_run(testpath)
849 def test_no_teardown_if_setupclass_failed(testdir): argument
850 testpath = testdir.makepyfile(
873 reprec = testdir.inline_run(testpath)
877 def test_cleanup_functions(testdir): argument
879 testdir.makepyfile(
898 result = testdir.runpytest("-v")
908 def test_issue333_result_clearing(testdir): argument
909 testdir.makeconftest(
918 testdir.makepyfile(
927 reprec = testdir.inline_run()
931 def test_unittest_raise_skip_issue748(testdir): argument
932 testdir.makepyfile(
941 result = testdir.runpytest("-v", "-rs")
950 def test_unittest_skip_issue1169(testdir): argument
951 testdir.makepyfile(
961 result = testdir.runpytest("-v", "-rs")
970 def test_class_method_containing_test_issue1558(testdir): argument
971 testdir.makepyfile(
983 reprec = testdir.inline_run()
988 def test_usefixtures_marker_on_unittest(base, testdir): argument
992 testdir.makepyfile(
1021 testdir.makepyfile(
1046 result = testdir.runpytest("-s")
1050 def test_testcase_handles_init_exceptions(testdir): argument
1055 testdir.makepyfile(
1066 result = testdir.runpytest()
1071 def test_error_message_with_parametrized_fixtures(testdir): argument
1072 testdir.copy_example("unittest/test_parametrized_fixture_error_message.py")
1073 result = testdir.runpytest()
1091 def test_setup_inheritance_skipping(testdir, test_name, expected_outcome): argument
1093 testdir.copy_example("unittest/{}".format(test_name))
1094 result = testdir.runpytest()
1098 def test_BdbQuit(testdir): argument
1099 testdir.makepyfile(
1112 reprec = testdir.inline_run()
1116 def test_exit_outcome(testdir): argument
1117 testdir.makepyfile(
1130 result = testdir.runpytest()
1134 def test_trace(testdir, monkeypatch): argument
1149 p1 = testdir.makepyfile(
1158 result = testdir.runpytest("--trace", str(p1))
1163 def test_pdb_teardown_called(testdir, monkeypatch) -> None: argument
1174 testdir.makepyfile(
1190 result = testdir.runpytest_inprocess("--pdb")
1199 def test_pdb_teardown_skipped(testdir, monkeypatch, mark: str) -> None: argument
1204 testdir.makepyfile(
1225 result = testdir.runpytest_inprocess("--pdb")
1230 def test_async_support(testdir): argument
1233 testdir.copy_example("unittest/test_unittest_asyncio.py")
1234 reprec = testdir.inline_run()
1238 def test_asynctest_support(testdir): argument
1242 testdir.copy_example("unittest/test_unittest_asynctest.py")
1243 reprec = testdir.inline_run()
1247 def test_plain_unittest_does_not_support_async(testdir): argument
1255 testdir.copy_example("unittest/test_unittest_plain_async.py")
1256 result = testdir.runpytest_subprocess()