summaryrefslogtreecommitdiffstats
path: root/meta-python/recipes-devtools/python
diff options
context:
space:
mode:
Diffstat (limited to 'meta-python/recipes-devtools/python')
-rw-r--r--meta-python/recipes-devtools/python/python3-dominate/58f7d7fdb171f80ed6ce97e6ca4409723975c47f.patch40
-rw-r--r--meta-python/recipes-devtools/python/python3-dominate_2.9.1.bb1
2 files changed, 41 insertions, 0 deletions
diff --git a/meta-python/recipes-devtools/python/python3-dominate/58f7d7fdb171f80ed6ce97e6ca4409723975c47f.patch b/meta-python/recipes-devtools/python/python3-dominate/58f7d7fdb171f80ed6ce97e6ca4409723975c47f.patch
new file mode 100644
index 0000000000..e3d0d485ee
--- /dev/null
+++ b/meta-python/recipes-devtools/python/python3-dominate/58f7d7fdb171f80ed6ce97e6ca4409723975c47f.patch
@@ -0,0 +1,40 @@
1From 58f7d7fdb171f80ed6ce97e6ca4409723975c47f Mon Sep 17 00:00:00 2001
2From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
3Date: Sat, 3 Aug 2024 16:07:38 +0200
4Subject: [PATCH] Update tests for docstring dedenting in Python 3.13
5
6Update the `get_expected()` function to account for the fact that
7Python 3.13 automatically dedents all the docstrings, and therefore
8does not require explicitly removing the indent (which effectively
9removes too much indent).
10
11Fixes #199
12
13Upstream-Status: Submitted [https://github.com/Knio/dominate/pull/202]
14Signed-off-by: Khem Raj <raj.khem@gmail.com>
15---
16 tests/test_svg.py | 7 ++++++-
17 1 file changed, 6 insertions(+), 1 deletion(-)
18
19diff --git a/tests/test_svg.py b/tests/test_svg.py
20index e5bbec3..ea7d98f 100644
21--- a/tests/test_svg.py
22+++ b/tests/test_svg.py
23@@ -1,3 +1,5 @@
24+import sys
25+
26 import dominate.svg
27 from dominate.tags import *
28 from dominate.svg import *
29@@ -14,7 +16,10 @@ def base():
30
31
32 def get_expected(func):
33- return func.__doc__.replace('\n ', '\n').strip()
34+ doc = func.__doc__
35+ if sys.version_info < (3, 13):
36+ doc = doc.replace('\n ', '\n')
37+ return doc.strip()
38
39
40 def output_test(func):
diff --git a/meta-python/recipes-devtools/python/python3-dominate_2.9.1.bb b/meta-python/recipes-devtools/python/python3-dominate_2.9.1.bb
index 054d5236e5..cce304498a 100644
--- a/meta-python/recipes-devtools/python/python3-dominate_2.9.1.bb
+++ b/meta-python/recipes-devtools/python/python3-dominate_2.9.1.bb
@@ -7,6 +7,7 @@ SRC_URI[sha256sum] = "558284687d9b8aae1904e3d6051ad132dd4a8c0cf551b37ea4e7e42a31
7inherit pypi ptest python_setuptools_build_meta 7inherit pypi ptest python_setuptools_build_meta
8 8
9SRC_URI += " \ 9SRC_URI += " \
10 file://58f7d7fdb171f80ed6ce97e6ca4409723975c47f.patch \
10 file://run-ptest \ 11 file://run-ptest \
11" 12"
12 13