diff options
| author | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2025-12-02 11:01:19 +0100 |
|---|---|---|
| committer | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2025-12-03 15:25:46 +0100 |
| commit | 39c74e4317c1f4b34a2d0d66a721b44a5adc652f (patch) | |
| tree | 5db77d05e47a74723fb8e944a012352cb8decf11 /sources/shiboken6/tests/samplebinding/oddbool_test.py | |
| parent | 57d79452870c5d6358fcb519a58f76ca9b4edc61 (diff) | |
shiboken6: Split out the spaceship operator tests
On this occasion, add a test for a free operator<=>()
behind guards.
Task-number: PYSIDE-3245
Change-Id: Ife8f17add0a8f1c3bd1194a5dfabce4f97c78006
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Diffstat (limited to 'sources/shiboken6/tests/samplebinding/oddbool_test.py')
| -rw-r--r-- | sources/shiboken6/tests/samplebinding/oddbool_test.py | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/sources/shiboken6/tests/samplebinding/oddbool_test.py b/sources/shiboken6/tests/samplebinding/oddbool_test.py index 2d48556de..290d9de61 100644 --- a/sources/shiboken6/tests/samplebinding/oddbool_test.py +++ b/sources/shiboken6/tests/samplebinding/oddbool_test.py @@ -14,7 +14,7 @@ sys.path.append(os.fspath(Path(__file__).resolve().parents[1])) from shiboken_paths import init_paths init_paths() -from sample import OddBoolUser, ComparisonTester, SpaceshipComparisonTester +from sample import OddBoolUser, ComparisonTester class DerivedOddBoolUser (OddBoolUser): @@ -62,19 +62,6 @@ class OddBoolTest(unittest.TestCase): t2 = ComparisonTester(42) self.assertEqual(t1, t2) - def testSpaceshipOperator(self): - if not SpaceshipComparisonTester.Enabled.HasSpaceshipOperator: - print("Skipping Spaceship Operator test") - return - t1 = SpaceshipComparisonTester(42) - t2 = SpaceshipComparisonTester(42) - self.assertEqual(t1, t2) - self.assertTrue(t1 <= t2) - self.assertTrue(t1 >= t2) - t2 = SpaceshipComparisonTester(43) - self.assertTrue(t1 < t2) - self.assertFalse(t1 > t2) - if __name__ == '__main__': unittest.main() |
