mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-07-31 23:08:09 -07:00
add dev-python/pytest-console-scripts pass -p to epytest Closes: https://bugs.gentoo.org/937953 Signed-off-by: Oz Tiram <oz.tiram@gmail.com> Signed-off-by: Petr Vaněk <arkamar@gentoo.org>
25 lines
1009 B
Diff
25 lines
1009 B
Diff
diff --git a/tests/test_non_host.py b/tests/test_non_host.py
|
|
index 2849375..ed7b7b3 100644
|
|
--- a/tests/test_non_host.py
|
|
+++ b/tests/test_non_host.py
|
|
@@ -1,5 +1,6 @@
|
|
from __future__ import annotations
|
|
|
|
+import json
|
|
import sys
|
|
from platform import python_implementation
|
|
from typing import TYPE_CHECKING
|
|
@@ -31,10 +32,10 @@ def test_custom_interpreter(
|
|
result = virtualenv.cli_run([str(tmp_path / "venv"), "--activators", ""])
|
|
py = str(result.creator.exe.relative_to(tmp_path))
|
|
cmd = ["", f"--python={result.creator.exe}"] if args_joined else ["", "--python", py]
|
|
- mocker.patch("pipdeptree._discovery.sys.argv", cmd)
|
|
+ mocker.patch("pipdeptree._discovery.sys.argv", [*cmd, "-j"])
|
|
main()
|
|
out, _ = capfd.readouterr()
|
|
- found = {i.split("==")[0] for i in out.splitlines()}
|
|
+ found = {i["package"]["package_name"] for i in json.loads(out)}
|
|
implementation = python_implementation()
|
|
if implementation == "CPython":
|
|
expected = {"pip", "setuptools", "wheel"}
|