START: ptest-runner 2023-10-13T17:54 BEGIN: /usr/lib/python3-pytest-mock/ptest ============================= test session starts ============================== platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0 rootdir: /usr/lib/python3-pytest-mock/ptest plugins: mock-3.11.2.dev0+gd3e73f2.d20230615 collected 83 items PASS: tests/test_pytest_mock.py::test_mock_patches[mock_using_patch_object] PASS: tests/test_pytest_mock.py::test_mock_patches[mock_using_patch] PASS: tests/test_pytest_mock.py::test_mock_patches[mock_using_patch_multiple] PASS: tests/test_pytest_mock.py::test_mock_patch_dict PASS: tests/test_pytest_mock.py::test_mock_patch_dict_resetall PASS: tests/test_pytest_mock.py::test_mocker_aliases[ANY] PASS: tests/test_pytest_mock.py::test_mocker_aliases[call] PASS: tests/test_pytest_mock.py::test_mocker_aliases[create_autospec] PASS: tests/test_pytest_mock.py::test_mocker_aliases[MagicMock] PASS: tests/test_pytest_mock.py::test_mocker_aliases[Mock] PASS: tests/test_pytest_mock.py::test_mocker_aliases[mock_open] PASS: tests/test_pytest_mock.py::test_mocker_aliases[NonCallableMagicMock] PASS: tests/test_pytest_mock.py::test_mocker_aliases[NonCallableMock] PASS: tests/test_pytest_mock.py::test_mocker_aliases[PropertyMock] PASS: tests/test_pytest_mock.py::test_mocker_aliases[sentinel] PASS: tests/test_pytest_mock.py::test_mocker_aliases[seal] PASS: tests/test_pytest_mock.py::test_mocker_resetall PASS: tests/test_pytest_mock.py::TestMockerStub::test_call PASS: tests/test_pytest_mock.py::TestMockerStub::test_repr_with_no_name PASS: tests/test_pytest_mock.py::TestMockerStub::test_repr_with_name PASS: tests/test_pytest_mock.py::TestMockerStub::test_failure_message_with_no_name PASS: tests/test_pytest_mock.py::TestMockerStub::test_failure_message_with_name[None] PASS: tests/test_pytest_mock.py::TestMockerStub::test_failure_message_with_name[] PASS: tests/test_pytest_mock.py::TestMockerStub::test_failure_message_with_name[f] PASS: tests/test_pytest_mock.py::TestMockerStub::test_failure_message_with_name[The Castle of aaarrrrggh] PASS: tests/test_pytest_mock.py::TestMockerStub::test_async_stub_type PASS: tests/test_pytest_mock.py::test_instance_method_spy PASS: tests/test_pytest_mock.py::test_instance_method_spy_exception[BaseException] PASS: tests/test_pytest_mock.py::test_instance_method_spy_exception[Exception] PASS: tests/test_pytest_mock.py::test_instance_method_spy_exception[GeneratorExit] PASS: tests/test_pytest_mock.py::test_instance_method_spy_exception[KeyboardInterrupt] PASS: tests/test_pytest_mock.py::test_instance_method_spy_exception[RuntimeError] PASS: tests/test_pytest_mock.py::test_instance_method_spy_exception[SystemExit] PASS: tests/test_pytest_mock.py::test_instance_method_spy_autospec_true PASS: tests/test_pytest_mock.py::test_spy_reset PASS: tests/test_pytest_mock.py::test_instance_method_by_class_spy PASS: tests/test_pytest_mock.py::test_instance_method_by_subclass_spy PASS: tests/test_pytest_mock.py::test_class_method_spy PASS: tests/test_pytest_mock.py::test_class_method_spy_autospec_false PASS: tests/test_pytest_mock.py::test_class_method_subclass_spy PASS: tests/test_pytest_mock.py::test_class_method_with_metaclass_spy PASS: tests/test_pytest_mock.py::test_static_method_spy PASS: tests/test_pytest_mock.py::test_static_method_subclass_spy PASS: tests/test_pytest_mock.py::test_callable_like_spy tests/test_pytest_mock.py::test_instance_async_method_spy SKIP (a...) PASS: tests/test_pytest_mock.py::test_assert_not_called_wrapper PASS: tests/test_pytest_mock.py::test_assert_called_with_wrapper PASS: tests/test_pytest_mock.py::test_assert_called_once_with_wrapper PASS: tests/test_pytest_mock.py::test_assert_called_once_wrapper PASS: tests/test_pytest_mock.py::test_assert_called_wrapper SKIP: tests/test_pytest_mock.py::test_assert_called_args_with_introspection SKIP: tests/test_pytest_mock.py::test_assert_called_kwargs_with_introspection PASS: tests/test_pytest_mock.py::test_assert_any_call_wrapper PASS: tests/test_pytest_mock.py::test_assert_has_calls PASS: tests/test_pytest_mock.py::test_assert_has_calls_multiple_calls PASS: tests/test_pytest_mock.py::test_assert_has_calls_multiple_calls_subset PASS: tests/test_pytest_mock.py::test_assert_has_calls_multiple_calls_any_order PASS: tests/test_pytest_mock.py::test_assert_has_calls_multiple_calls_any_order_subset PASS: tests/test_pytest_mock.py::test_assert_has_calls_no_calls PASS: tests/test_pytest_mock.py::test_monkeypatch_ini PASS: tests/test_pytest_mock.py::test_parse_ini_boolean PASS: tests/test_pytest_mock.py::test_patched_method_parameter_name PASS: tests/test_pytest_mock.py::test_monkeypatch_native PASS: tests/test_pytest_mock.py::test_monkeypatch_no_terminal tests/test_pytest_mock.py::test_standalone_mock SKIP (could not i...) PASS: tests/test_pytest_mock.py::test_detailed_introspection FAIL: tests/test_pytest_mock.py::test_detailed_introspection_async PASS: tests/test_pytest_mock.py::test_missing_introspection PASS: tests/test_pytest_mock.py::test_assert_called_with_unicode_arguments FAIL: tests/test_pytest_mock.py::test_plain_stopall PASS: tests/test_pytest_mock.py::test_warn_patch_object_context_manager PASS: tests/test_pytest_mock.py::test_warn_patch_context_manager PASS: tests/test_pytest_mock.py::test_context_manager_patch_example PASS: tests/test_pytest_mock.py::test_patch_context_manager_with_context_manager PASS: tests/test_pytest_mock.py::test_abort_patch_context_manager_with_stale_pyc FAIL: tests/test_pytest_mock.py::test_used_with_class_scope FAIL: tests/test_pytest_mock.py::test_used_with_module_scope FAIL: tests/test_pytest_mock.py::test_used_with_package_scope FAIL: tests/test_pytest_mock.py::test_used_with_session_scope PASS: tests/test_pytest_mock.py::test_stop_patch PASS: tests/test_pytest_mock.py::test_stop_instance_patch PASS: tests/test_pytest_mock.py::test_stop_spy PASS: tests/test_pytest_mock.py::test_stop_instance_spy =================================== FAILURES =================================== ______________________ test_detailed_introspection_async _______________________ testdir = @pytest.mark.skipif( sys.version_info < (3, 8), reason="AsyncMock is present on 3.8 and above" ) @pytest.mark.usefixtures("needs_assert_rewrite") def test_detailed_introspection_async(testdir: Any) -> None: """Check that the "mock_use_standalone" is being used.""" testdir.makeini( """ [pytest] asyncio_mode=auto """ ) testdir.makepyfile( """ import pytest async def test(mocker): m = mocker.AsyncMock() await m('fo') m.assert_awaited_once_with('', bar=4) """ ) result = testdir.runpytest("-s") expected_lines = [ "*AssertionError: expected await not found.", "*Expected: mock('', bar=4)", "*Actual: mock('fo')", "*pytest introspection follows:*", "*Args:", "*assert ('fo',) == ('',)", "*At index 0 diff: 'fo' != ''*", "*Use -v to get more diff*", "*Kwargs:*", "*assert {} == {'bar': 4}*", "*Right contains* more item*", "*{'bar': 4}*", "*Use -v to get more diff*", ] > result.stdout.fnmatch_lines(expected_lines) E Failed: nomatch: '*AssertionError: expected await not found.' E and: '============================= test session starts ==============================' E and: 'platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0' E and: 'rootdir: /tmp/pytest-of-unknown/pytest-0/test_detailed_introspection_async0' E and: 'configfile: tox.ini' E and: 'plugins: mock-3.11.2.dev0+gd3e73f2.d20230615' E and: 'collected 1 item' E and: '' E and: 'test_detailed_introspection_async.py s' E and: '' E and: '=============================== warnings summary ===============================' E and: '../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373' E and: ' /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode' E and: ' ' E and: ' self._warn_or_fail_if_strict(f"Unknown config option: {key}\\n")' E and: '' E and: 'test_detailed_introspection_async.py::test' E and: ' /usr/lib/python3.11/site-packages/_pytest/python.py:183: PytestUnhandledCoroutineWarning: async def functions are not natively supported and have been skipped.' E and: ' You need to install a suitable plugin for your async framework, for example:' E and: ' - anyio' E and: ' - pytest-asyncio' E and: ' - pytest-tornasync' E and: ' - pytest-trio' E and: ' - pytest-twisted' E and: ' warnings.warn(PytestUnhandledCoroutineWarning(msg.format(nodeid)))' E and: '' E and: '-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html' E and: '======================== 1 skipped, 2 warnings in 0.01s ========================' E remains unmatched: '*AssertionError: expected await not found.' /usr/lib/python3-pytest-mock/ptest/tests/test_pytest_mock.py:904: Failed ----------------------------- Captured stdout call ----------------------------- ============================= test session starts ============================== platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0 rootdir: /tmp/pytest-of-unknown/pytest-0/test_detailed_introspection_async0 configfile: tox.ini plugins: mock-3.11.2.dev0+gd3e73f2.d20230615 collected 1 item test_detailed_introspection_async.py s =============================== warnings summary =============================== ../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373 /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode self._warn_or_fail_if_strict(f"Unknown config option: {key}\n") test_detailed_introspection_async.py::test /usr/lib/python3.11/site-packages/_pytest/python.py:183: PytestUnhandledCoroutineWarning: async def functions are not natively supported and have been skipped. You need to install a suitable plugin for your async framework, for example: - anyio - pytest-asyncio - pytest-tornasync - pytest-trio - pytest-twisted warnings.warn(PytestUnhandledCoroutineWarning(msg.format(nodeid))) -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ======================== 1 skipped, 2 warnings in 0.01s ======================== ______________________________ test_plain_stopall ______________________________ testdir = def test_plain_stopall(testdir: Any) -> None: """patch.stopall() in a test should not cause an error during unconfigure (#137)""" testdir.makeini( """ [pytest] asyncio_mode=auto """ ) testdir.makepyfile( """ import random def get_random_number(): return random.randint(0, 100) def test_get_random_number(mocker): patcher = mocker.mock_module.patch("random.randint", lambda x, y: 5) patcher.start() assert get_random_number() == 5 mocker.mock_module.patch.stopall() """ ) result = testdir.runpytest_subprocess() > result.stdout.fnmatch_lines("* 1 passed in *") E Failed: nomatch: '* 1 passed in *' E and: '============================= test session starts ==============================' E and: 'platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0' E and: 'rootdir: /tmp/pytest-of-unknown/pytest-0/test_plain_stopall0' E and: 'configfile: tox.ini' E and: 'plugins: mock-3.11.2.dev0+gd3e73f2.d20230615' E and: 'collected 1 item' E and: '' E and: 'test_plain_stopall.py . ' E and: '' E and: '=============================== warnings summary ===============================' E and: '../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373' E and: ' /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode' E and: ' ' E and: ' self._warn_or_fail_if_strict(f"Unknown config option: {key}\\n")' E and: '' E and: '-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html' E and: '========================= 1 passed, 1 warning in 0.01s =========================' E remains unmatched: '* 1 passed in *' /usr/lib/python3-pytest-mock/ptest/tests/test_pytest_mock.py:953: Failed ----------------------------- Captured stdout call ----------------------------- running: /usr/bin/python3 -mpytest --basetemp=/tmp/pytest-of-unknown/pytest-0/test_plain_stopall0/runpytest-0 in: /tmp/pytest-of-unknown/pytest-0/test_plain_stopall0 ============================= test session starts ============================== platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0 rootdir: /tmp/pytest-of-unknown/pytest-0/test_plain_stopall0 configfile: tox.ini plugins: mock-3.11.2.dev0+gd3e73f2.d20230615 collected 1 item test_plain_stopall.py . =============================== warnings summary =============================== ../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373 /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode self._warn_or_fail_if_strict(f"Unknown config option: {key}\n") -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ========================= 1 passed, 1 warning in 0.01s ========================= __________________________ test_used_with_class_scope __________________________ testdir = def test_used_with_class_scope(testdir: Any) -> None: testdir.makeini( """ [pytest] asyncio_mode=auto """ ) testdir.makepyfile( """ import pytest import random import unittest def get_random_number(): return random.randint(0, 1) @pytest.fixture(autouse=True, scope="class") def randint_mock(class_mocker): return class_mocker.patch("random.randint", lambda x, y: 5) class TestGetRandomNumber(unittest.TestCase): def test_get_random_number(self): assert get_random_number() == 5 """ ) result = testdir.runpytest_subprocess() assert "AssertionError" not in result.stderr.str() > result.stdout.fnmatch_lines("* 1 passed in *") E Failed: nomatch: '* 1 passed in *' E and: '============================= test session starts ==============================' E and: 'platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0' E and: 'rootdir: /tmp/pytest-of-unknown/pytest-0/test_used_with_class_scope0' E and: 'configfile: tox.ini' E and: 'plugins: mock-3.11.2.dev0+gd3e73f2.d20230615' E and: 'collected 1 item' E and: '' E and: 'test_used_with_class_scope.py . ' E and: '' E and: '=============================== warnings summary ===============================' E and: '../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373' E and: ' /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode' E and: ' ' E and: ' self._warn_or_fail_if_strict(f"Unknown config option: {key}\\n")' E and: '' E and: '-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html' E and: '========================= 1 passed, 1 warning in 0.01s =========================' E remains unmatched: '* 1 passed in *' /usr/lib/python3-pytest-mock/ptest/tests/test_pytest_mock.py:1098: Failed ----------------------------- Captured stdout call ----------------------------- running: /usr/bin/python3 -mpytest --basetemp=/tmp/pytest-of-unknown/pytest-0/test_used_with_class_scope0/runpytest-0 in: /tmp/pytest-of-unknown/pytest-0/test_used_with_class_scope0 ============================= test session starts ============================== platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0 rootdir: /tmp/pytest-of-unknown/pytest-0/test_used_with_class_scope0 configfile: tox.ini plugins: mock-3.11.2.dev0+gd3e73f2.d20230615 collected 1 item test_used_with_class_scope.py . =============================== warnings summary =============================== ../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373 /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode self._warn_or_fail_if_strict(f"Unknown config option: {key}\n") -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ========================= 1 passed, 1 warning in 0.01s ========================= _________________________ test_used_with_module_scope __________________________ testdir = def test_used_with_module_scope(testdir: Any) -> None: testdir.makeini( """ [pytest] asyncio_mode=auto """ ) testdir.makepyfile( """ import pytest import random def get_random_number(): return random.randint(0, 1) @pytest.fixture(autouse=True, scope="module") def randint_mock(module_mocker): return module_mocker.patch("random.randint", lambda x, y: 5) def test_get_random_number(): assert get_random_number() == 5 """ ) result = testdir.runpytest_subprocess() assert "AssertionError" not in result.stderr.str() > result.stdout.fnmatch_lines("* 1 passed in *") E Failed: nomatch: '* 1 passed in *' E and: '============================= test session starts ==============================' E and: 'platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0' E and: 'rootdir: /tmp/pytest-of-unknown/pytest-0/test_used_with_module_scope0' E and: 'configfile: tox.ini' E and: 'plugins: mock-3.11.2.dev0+gd3e73f2.d20230615' E and: 'collected 1 item' E and: '' E and: 'test_used_with_module_scope.py . ' E and: '' E and: '=============================== warnings summary ===============================' E and: '../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373' E and: ' /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode' E and: ' ' E and: ' self._warn_or_fail_if_strict(f"Unknown config option: {key}\\n")' E and: '' E and: '-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html' E and: '========================= 1 passed, 1 warning in 0.02s =========================' E remains unmatched: '* 1 passed in *' /usr/lib/python3-pytest-mock/ptest/tests/test_pytest_mock.py:1126: Failed ----------------------------- Captured stdout call ----------------------------- running: /usr/bin/python3 -mpytest --basetemp=/tmp/pytest-of-unknown/pytest-0/test_used_with_module_scope0/runpytest-0 in: /tmp/pytest-of-unknown/pytest-0/test_used_with_module_scope0 ============================= test session starts ============================== platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0 rootdir: /tmp/pytest-of-unknown/pytest-0/test_used_with_module_scope0 configfile: tox.ini plugins: mock-3.11.2.dev0+gd3e73f2.d20230615 collected 1 item test_used_with_module_scope.py . =============================== warnings summary =============================== ../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373 /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode self._warn_or_fail_if_strict(f"Unknown config option: {key}\n") -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ========================= 1 passed, 1 warning in 0.02s ========================= _________________________ test_used_with_package_scope _________________________ testdir = def test_used_with_package_scope(testdir: Any) -> None: testdir.makeini( """ [pytest] asyncio_mode=auto """ ) testdir.makepyfile( """ import pytest import random def get_random_number(): return random.randint(0, 1) @pytest.fixture(autouse=True, scope="package") def randint_mock(package_mocker): return package_mocker.patch("random.randint", lambda x, y: 5) def test_get_random_number(): assert get_random_number() == 5 """ ) result = testdir.runpytest_subprocess() assert "AssertionError" not in result.stderr.str() > result.stdout.fnmatch_lines("* 1 passed in *") E Failed: nomatch: '* 1 passed in *' E and: '============================= test session starts ==============================' E and: 'platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0' E and: 'rootdir: /tmp/pytest-of-unknown/pytest-0/test_used_with_package_scope0' E and: 'configfile: tox.ini' E and: 'plugins: mock-3.11.2.dev0+gd3e73f2.d20230615' E and: 'collected 1 item' E and: '' E and: 'test_used_with_package_scope.py . ' E and: '' E and: '=============================== warnings summary ===============================' E and: '../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373' E and: ' /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode' E and: ' ' E and: ' self._warn_or_fail_if_strict(f"Unknown config option: {key}\\n")' E and: '' E and: '-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html' E and: '========================= 1 passed, 1 warning in 0.01s =========================' E remains unmatched: '* 1 passed in *' /usr/lib/python3-pytest-mock/ptest/tests/test_pytest_mock.py:1154: Failed ----------------------------- Captured stdout call ----------------------------- running: /usr/bin/python3 -mpytest --basetemp=/tmp/pytest-of-unknown/pytest-0/test_used_with_package_scope0/runpytest-0 in: /tmp/pytest-of-unknown/pytest-0/test_used_with_package_scope0 ============================= test session starts ============================== platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0 rootdir: /tmp/pytest-of-unknown/pytest-0/test_used_with_package_scope0 configfile: tox.ini plugins: mock-3.11.2.dev0+gd3e73f2.d20230615 collected 1 item test_used_with_package_scope.py . =============================== warnings summary =============================== ../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373 /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode self._warn_or_fail_if_strict(f"Unknown config option: {key}\n") -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ========================= 1 passed, 1 warning in 0.01s ========================= _________________________ test_used_with_session_scope _________________________ testdir = def test_used_with_session_scope(testdir: Any) -> None: testdir.makeini( """ [pytest] asyncio_mode=auto """ ) testdir.makepyfile( """ import pytest import random def get_random_number(): return random.randint(0, 1) @pytest.fixture(autouse=True, scope="session") def randint_mock(session_mocker): return session_mocker.patch("random.randint", lambda x, y: 5) def test_get_random_number(): assert get_random_number() == 5 """ ) result = testdir.runpytest_subprocess() assert "AssertionError" not in result.stderr.str() > result.stdout.fnmatch_lines("* 1 passed in *") E Failed: nomatch: '* 1 passed in *' E and: '============================= test session starts ==============================' E and: 'platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0' E and: 'rootdir: /tmp/pytest-of-unknown/pytest-0/test_used_with_session_scope0' E and: 'configfile: tox.ini' E and: 'plugins: mock-3.11.2.dev0+gd3e73f2.d20230615' E and: 'collected 1 item' E and: '' E and: 'test_used_with_session_scope.py . ' E and: '' E and: '=============================== warnings summary ===============================' E and: '../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373' E and: ' /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode' E and: ' ' E and: ' self._warn_or_fail_if_strict(f"Unknown config option: {key}\\n")' E and: '' E and: '-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html' E and: '========================= 1 passed, 1 warning in 0.01s =========================' E remains unmatched: '* 1 passed in *' /usr/lib/python3-pytest-mock/ptest/tests/test_pytest_mock.py:1182: Failed ----------------------------- Captured stdout call ----------------------------- running: /usr/bin/python3 -mpytest --basetemp=/tmp/pytest-of-unknown/pytest-0/test_used_with_session_scope0/runpytest-0 in: /tmp/pytest-of-unknown/pytest-0/test_used_with_session_scope0 ============================= test session starts ============================== platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0 rootdir: /tmp/pytest-of-unknown/pytest-0/test_used_with_session_scope0 configfile: tox.ini plugins: mock-3.11.2.dev0+gd3e73f2.d20230615 collected 1 item test_used_with_session_scope.py . =============================== warnings summary =============================== ../../../../usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373 /usr/lib/python3.11/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode self._warn_or_fail_if_strict(f"Unknown config option: {key}\n") -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ========================= 1 passed, 1 warning in 0.01s ========================= =============================== warnings summary =============================== tests/test_pytest_mock.py::test_instance_async_method_spy /usr/lib/python3.11/site-packages/_pytest/python.py:183: PytestUnhandledCoroutineWarning: async def functions are not natively supported and have been skipped. You need to install a suitable plugin for your async framework, for example: - anyio - pytest-asyncio - pytest-tornasync - pytest-trio - pytest-twisted warnings.warn(PytestUnhandledCoroutineWarning(msg.format(nodeid))) -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html =========================== short test summary info ============================ FAIL tests/test_pytest_mock.py::test_detailed_introspection_async - Failed:... FAIL tests/test_pytest_mock.py::test_plain_stopall - Failed: nomatch: '* 1 ... FAIL tests/test_pytest_mock.py::test_used_with_class_scope - Failed: nomatc... FAIL tests/test_pytest_mock.py::test_used_with_module_scope - Failed: nomat... FAIL tests/test_pytest_mock.py::test_used_with_package_scope - Failed: noma... FAIL tests/test_pytest_mock.py::test_used_with_session_scope - Failed: noma... ============== 6 failed, 73 passed, 4 skipped, 1 warning in 4.69s ============== DURATION: 5 END: /usr/lib/python3-pytest-mock/ptest 2023-10-13T17:54 STOP: ptest-runner TOTAL: 1 FAIL: 0