1 |
commit: 61a8fec347738d27d8daf70f10439b1f2754e2e8 |
2 |
Author: Arthur Zamarin <arthurzam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Oct 15 19:52:08 2021 +0000 |
4 |
Commit: Arthur Zamarin <arthurzam <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Oct 15 19:53:44 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=61a8fec3 |
7 |
|
8 |
dev-python/pytest-xdist: backport fix testing with xprocess |
9 |
|
10 |
backport fix by mgorny for testing when pytest-xprocess is |
11 |
installed. |
12 |
|
13 |
Closes: https://bugs.gentoo.org/813093 |
14 |
Signed-off-by: Arthur Zamarin <arthurzam <AT> gentoo.org> |
15 |
|
16 |
dev-python/pytest-xdist/pytest-xdist-2.3.0.ebuild | 10 ++++++++++ |
17 |
1 file changed, 10 insertions(+) |
18 |
|
19 |
diff --git a/dev-python/pytest-xdist/pytest-xdist-2.3.0.ebuild b/dev-python/pytest-xdist/pytest-xdist-2.3.0.ebuild |
20 |
index c151147a967..883e7c88dce 100644 |
21 |
--- a/dev-python/pytest-xdist/pytest-xdist-2.3.0.ebuild |
22 |
+++ b/dev-python/pytest-xdist/pytest-xdist-2.3.0.ebuild |
23 |
@@ -35,3 +35,13 @@ PATCHES=( |
24 |
) |
25 |
|
26 |
distutils_enable_tests --install pytest |
27 |
+ |
28 |
+python_test() { |
29 |
+ # disable autoloading plugins in nested pytest calls |
30 |
+ local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 |
31 |
+ # since we disabled autoloading, force loading necessary plugins |
32 |
+ local -x PYTEST_PLUGINS=xdist.plugin,xdist.looponfail,pytest_forked |
33 |
+ |
34 |
+ distutils_install_for_testing |
35 |
+ epytest |
36 |
+} |