From 9103a16e1da48dae25563e59a213fcf0f97706b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Date: Fri, 28 Jan 2022 23:14:15 +0100 Subject: [PATCH] dev-python/pytest-mock: Disable plugin autoloading during tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Michał Górny --- dev-python/pytest-mock/pytest-mock-3.7.0.ebuild | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/dev-python/pytest-mock/pytest-mock-3.7.0.ebuild b/dev-python/pytest-mock/pytest-mock-3.7.0.ebuild index 741a457784be8..3e6c060c2c67c 100644 --- a/dev-python/pytest-mock/pytest-mock-3.7.0.ebuild +++ b/dev-python/pytest-mock/pytest-mock-3.7.0.ebuild @@ -25,12 +25,10 @@ BDEPEND=" distutils_enable_tests pytest -src_prepare() { - sed -e 's/runpytest_subprocess(/&"-p","no:xprocess",/' -i tests/test_pytest_mock.py || die - distutils-r1_src_prepare -} - python_test() { + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + local -x PYTEST_PLUGINS=pytest_mock,pytest_asyncio.plugin + if has_version dev-python/mock; then local EPYTEST_DESELECT=( tests/test_pytest_mock.py::test_standalone_mock