From: "Thomas Beierlein" <tomjbe@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pygccxml/files/, dev-python/pygccxml/
Date: Mon, 26 Aug 2024 20:07:02 +0000 (UTC) [thread overview]
Message-ID: <1724702791.221b27ca6002eaccdd6a9bd30fab9eee8894c7e1.tomjbe@gentoo> (raw)
commit: 221b27ca6002eaccdd6a9bd30fab9eee8894c7e1
Author: Thomas Beierlein <tomjbe <AT> gentoo <DOT> org>
AuthorDate: Mon Aug 26 20:05:26 2024 +0000
Commit: Thomas Beierlein <tomjbe <AT> gentoo <DOT> org>
CommitDate: Mon Aug 26 20:06:31 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=221b27ca
dev-python/pygccxml: Fix tests
Closes: https://bugs.gentoo.org/936005
Signed-off-by: Thomas Beierlein <tomjbe <AT> gentoo.org>
.../pygccxml/files/pygccxml-2.5.0-fix-tests.patch | 107 +++++++++++++++++++++
dev-python/pygccxml/pygccxml-2.5.0.ebuild | 1 +
2 files changed, 108 insertions(+)
diff --git a/dev-python/pygccxml/files/pygccxml-2.5.0-fix-tests.patch b/dev-python/pygccxml/files/pygccxml-2.5.0-fix-tests.patch
new file mode 100644
index 000000000000..5a65fd826fff
--- /dev/null
+++ b/dev-python/pygccxml/files/pygccxml-2.5.0-fix-tests.patch
@@ -0,0 +1,107 @@
+diff --git a/unittests/test_cpp_standards.py b/unittests/test_cpp_standards.py
+index eb28418..7c76c73 100644
+--- a/unittests/test_cpp_standards.py
++++ b/unittests/test_cpp_standards.py
+@@ -23,7 +23,8 @@ class Test(parser_test_case.parser_test_case_t):
+ if "gccxml" in self.config.xml_generator:
+ return True
+
+- parser.parse(["cpp_standards.hpp"], self.config)
++ parser.parse(["cpp_standards.hpp"], self.config,
++ parser.COMPILATION_MODE.ALL_AT_ONCE)
+
+ if platform.system() != 'Windows':
+ self.config.cflags = "-std=c++98"
+@@ -33,7 +34,8 @@ class Test(parser_test_case.parser_test_case_t):
+ parser.parse(["cpp_standards.hpp"], self.config)
+
+ self.config.cflags = "-std=c++11"
+- parser.parse(["cpp_standards.hpp"], self.config)
++ parser.parse(["cpp_standards.hpp"], self.config,
++ parser.COMPILATION_MODE.ALL_AT_ONCE)
+
+ # This is broken with llvm 3.6.2 (the one from homebrew)
+ # It should work with never llvms but I keep the test disabled
+diff --git a/unittests/test_non_copyable_recursive.py b/unittests/test_non_copyable_recursive.py
+index cd78a9a..e18d58f 100644
+--- a/unittests/test_non_copyable_recursive.py
++++ b/unittests/test_non_copyable_recursive.py
+@@ -27,7 +27,7 @@ class Test(parser_test_case.parser_test_case_t):
+ RuntimeError: maximum recursion depth exceeded while
+ calling a Python object
+ """
+- decls = parser.parse([self.header], self.config)
++ decls = parser.parse([self.header], self.config, parser.COMPILATION_MODE.ALL_AT_ONCE)
+ global_ns = declarations.get_global_namespace(decls)
+
+ # Description of the problem (before the fix):
+@@ -52,7 +52,7 @@ class Test(parser_test_case.parser_test_case_t):
+ RuntimeError: maximum recursion depth exceeded while
+ calling a Python object
+ """
+- decls = parser.parse([self.header], self.config)
++ decls = parser.parse([self.header], self.config, parser.COMPILATION_MODE.ALL_AT_ONCE)
+ global_ns = declarations.get_global_namespace(decls)
+
+ # Real life example of the bug. This leads to a similar error,
+diff --git a/unittests/test_null_comparison.py b/unittests/test_null_comparison.py
+index 51caf4a..787ae79 100644
+--- a/unittests/test_null_comparison.py
++++ b/unittests/test_null_comparison.py
+@@ -22,7 +22,7 @@ class Test(parser_test_case.parser_test_case_t):
+ Test for None comparisons with default arguments
+ """
+
+- decls = parser.parse([self.header], self.config)
++ decls = parser.parse([self.header], self.config, parser.COMPILATION_MODE.ALL_AT_ONCE)
+ global_ns = declarations.get_global_namespace(decls)
+
+ ns = global_ns.namespace("ns")
+diff --git a/unittests/test_overrides.py b/unittests/test_overrides.py
+index 9204efc..5ac1b25 100644
+--- a/unittests/test_overrides.py
++++ b/unittests/test_overrides.py
+@@ -23,7 +23,7 @@ class Test(parser_test_case.parser_test_case_t):
+ def setUp(self):
+
+ if not self.global_ns:
+- decls = parser.parse([self.header], self.config)
++ decls = parser.parse([self.header], self.config, parser.COMPILATION_MODE.ALL_AT_ONCE)
+ Test.global_ns = declarations.get_global_namespace(decls)
+ Test.xml_generator_from_xml_file = \
+ self.config.xml_generator_from_xml_file
+diff --git a/unittests/test_pattern_parser.py b/unittests/test_pattern_parser.py
+index 00a6805..4882c26 100644
+--- a/unittests/test_pattern_parser.py
++++ b/unittests/test_pattern_parser.py
+@@ -27,7 +27,7 @@ class Test(parser_test_case.parser_test_case_t):
+ if self.config.xml_generator == "gccxml":
+ return
+
+- decls = parser.parse([self.header], self.config)
++ decls = parser.parse([self.header], self.config, parser.COMPILATION_MODE.ALL_AT_ONCE)
+
+ for decl in declarations.make_flatten(decls):
+ if "myClass" in decl.name:
+@@ -44,7 +44,7 @@ class Test(parser_test_case.parser_test_case_t):
+ if self.config.xml_generator == "gccxml":
+ return
+
+- decls = parser.parse([self.header], self.config)
++ decls = parser.parse([self.header], self.config, parser.COMPILATION_MODE.ALL_AT_ONCE)
+ global_ns = declarations.get_global_namespace(decls)
+ criteria = declarations.declaration_matcher(name="myClass")
+ _ = declarations.matcher.find(criteria, global_ns)
+diff --git a/unittests/test_smart_pointer.py b/unittests/test_smart_pointer.py
+index e9183b7..4a85860 100644
+--- a/unittests/test_smart_pointer.py
++++ b/unittests/test_smart_pointer.py
+@@ -22,7 +22,7 @@ class Test(parser_test_case.parser_test_case_t):
+ def setUp(self):
+ if self.config.xml_generator == "gccxml":
+ return
+- decls = parser.parse([self.header], self.config)
++ decls = parser.parse([self.header], self.config, parser.COMPILATION_MODE.ALL_AT_ONCE)
+ self.global_ns = declarations.get_global_namespace(decls)
+
+ def test_is_smart_pointer(self):
diff --git a/dev-python/pygccxml/pygccxml-2.5.0.ebuild b/dev-python/pygccxml/pygccxml-2.5.0.ebuild
index ba61c6612e8e..f9950b4f3f47 100644
--- a/dev-python/pygccxml/pygccxml-2.5.0.ebuild
+++ b/dev-python/pygccxml/pygccxml-2.5.0.ebuild
@@ -40,6 +40,7 @@ EPYTEST_DESELECT=(
python_prepare_all() {
local PATCHES=(
+ "${FILESDIR}/${PN}-2.5.0-fix-tests.patch"
"${FILESDIR}/${PN}-2.4.0-doc.patch"
# https://github.com/CastXML/pygccxml/pull/179
"${FILESDIR}/${P}-which.patch"
next reply other threads:[~2024-08-26 20:07 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-26 20:07 Thomas Beierlein [this message]
-- strict thread matches above, loose matches on Subject: below --
2025-01-10 16:42 [gentoo-commits] repo/gentoo:master commit in: dev-python/pygccxml/files/, dev-python/pygccxml/ Thomas Beierlein
2024-10-28 18:46 Thomas Beierlein
2024-04-15 14:30 Michał Górny
2023-11-20 15:15 Thomas Beierlein
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1724702791.221b27ca6002eaccdd6a9bd30fab9eee8894c7e1.tomjbe@gentoo \
--to=tomjbe@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox