summaryrefslogtreecommitdiff
path: root/dev-python/fritzconnection
diff options
context:
space:
mode:
authorroot <root@alpha.trunkmasters.com>2026-07-09 03:04:33 -0500
committerroot <root@alpha.trunkmasters.com>2026-07-09 03:04:33 -0500
commita96a971c845e2cd3ffad3b8f63558c6408897f0a (patch)
tree9431452ee7738105e3d34fdaa7a4ac405c646c8b /dev-python/fritzconnection
parent897a58deb079b5691d4424cc15517aea6e422808 (diff)
downloadbaldeagleos-repo-a96a971c845e2cd3ffad3b8f63558c6408897f0a.tar.gz
baldeagleos-repo-a96a971c845e2cd3ffad3b8f63558c6408897f0a.tar.xz
baldeagleos-repo-a96a971c845e2cd3ffad3b8f63558c6408897f0a.zip
Adding metadata
Diffstat (limited to 'dev-python/fritzconnection')
-rw-r--r--dev-python/fritzconnection/files/fritzconnection-1.15.1-pytest-9.patch44
-rw-r--r--dev-python/fritzconnection/fritzconnection-1.15.1.ebuild5
2 files changed, 49 insertions, 0 deletions
diff --git a/dev-python/fritzconnection/files/fritzconnection-1.15.1-pytest-9.patch b/dev-python/fritzconnection/files/fritzconnection-1.15.1-pytest-9.patch
new file mode 100644
index 000000000000..104efc759506
--- /dev/null
+++ b/dev-python/fritzconnection/files/fritzconnection-1.15.1-pytest-9.patch
@@ -0,0 +1,44 @@
+From 19a0a03f1fc42b6a12118a4e431e67100a2e0489 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
+Date: Wed, 8 Jul 2026 11:08:02 +0200
+Subject: [PATCH] Fix duplicate test id for pytest-9
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Running the test suite using pytest-9 yields the following error:
+
+```
+______________________________________ ERROR collecting fritzconnection/tests/test_core_utils.py ______________________________________
+Duplicate parametrization IDs detected, but strict_parametrization_ids is set.
+
+Test name: fritzconnection/tests/test_core_utils.py::test_get_boolean_from_string
+Parameters: value, expected_result
+Parameter sets: ['true', True], ['false', False], ['wahr', None], ['falsch', None], ['None', None], [42, None], ['', None], [None, None]
+IDs: true-True, false-False, wahr-None, falsch-None, None-None, 42-None, -None, None-None
+Duplicates: None-None
+
+You can fix this problem using `@pytest.mark.parametrize(..., ids=...)` or `pytest.param(..., id=...)`.
+```
+
+This is because both `"None"` and `None` resolve to the same identifier.
+Override the identifier for the latter to fix the test suite.
+
+Signed-off-by: Michał Górny <mgorny@gentoo.org>
+---
+ fritzconnection/tests/test_core_utils.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/fritzconnection/tests/test_core_utils.py b/fritzconnection/tests/test_core_utils.py
+index 657a022f..180926d5 100644
+--- a/fritzconnection/tests/test_core_utils.py
++++ b/fritzconnection/tests/test_core_utils.py
+@@ -66,7 +66,7 @@ def test_boolean_from_string_typeerror(value):
+ ("None", None),
+ (42, None),
+ ("", None),
+- (None, None),
++ pytest.param(None, None, id="(None)-None"),
+ ]
+ )
+ def test_get_boolean_from_string(value, expected_result):
diff --git a/dev-python/fritzconnection/fritzconnection-1.15.1.ebuild b/dev-python/fritzconnection/fritzconnection-1.15.1.ebuild
index aad17f4d0b4b..1de6b2175b7c 100644
--- a/dev-python/fritzconnection/fritzconnection-1.15.1.ebuild
+++ b/dev-python/fritzconnection/fritzconnection-1.15.1.ebuild
@@ -39,6 +39,11 @@ RDEPEND="
EPYTEST_PLUGINS=( pytest-mock )
distutils_enable_tests pytest
+PATCHES=(
+ # https://github.com/kbr/fritzconnection/pull/269
+ "${FILESDIR}/${P}-pytest-9.patch"
+)
+
python_test() {
local EPYTEST_DESELECT=(
# flaky (relies on time.sleep(0.01) magically being sufficient)