aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Tismer <tismer@stackless.com>2021-06-10 11:53:26 +0200
committerChristian Tismer <tismer@stackless.com>2021-06-10 14:49:30 +0200
commit5237a185d3a89bf03af7699a3b2f3d3745d2e46c (patch)
tree75b137c0f65da3804b37adf396b11cd1740cd062
parent2b1cc890293592c9f40dcc14119b726886a20fe8 (diff)
Fix test that creates unrelated problems with palette
This old test is really redundant and suddenly creates errors. We replace it with a much easier version. Change-Id: I19327c9e1fab170a4bee954f7fe90419aeaec686 Pick-to: 6.1 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
-rw-r--r--sources/pyside6/tests/pysidetest/new_inherited_functions_test.py14
1 files changed, 3 insertions, 11 deletions
diff --git a/sources/pyside6/tests/pysidetest/new_inherited_functions_test.py b/sources/pyside6/tests/pysidetest/new_inherited_functions_test.py
index f4d83ad9f..77efbcb5f 100644
--- a/sources/pyside6/tests/pysidetest/new_inherited_functions_test.py
+++ b/sources/pyside6/tests/pysidetest/new_inherited_functions_test.py
@@ -181,17 +181,9 @@ class MainTest(unittest.TestCase):
PySide6.QtWidgets.QApplication([]))
except AttributeError:
unittest.TestCase().skipTest("this test makes only sense if QtWidgets is available.")
- try:
- PySide6.QtWidgets.QApplication.palette(42) # raises
- except TypeError as e:
- lines = e.args[0].splitlines()
- heading_pos = lines.index("Supported signatures:")
- lines = lines[heading_pos + 1:]
- self.assertEqual(len(lines), 3)
- txt = '\n'.join(lines)
- print("Signatures found:")
- print(txt)
- self.assertTrue("palette()" in txt)
+
+ sigs = PySide6.QtWidgets.QApplication.palette.__signature__
+ self.assertEqual(len(sigs), 3)
if __name__ == '__main__':