aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6/tests
diff options
context:
space:
mode:
Diffstat (limited to 'sources/pyside6/tests')
-rw-r--r--sources/pyside6/tests/QtCore/destroysignal_test.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/sources/pyside6/tests/QtCore/destroysignal_test.py b/sources/pyside6/tests/QtCore/destroysignal_test.py
index f1d7cfec1..ad087b489 100644
--- a/sources/pyside6/tests/QtCore/destroysignal_test.py
+++ b/sources/pyside6/tests/QtCore/destroysignal_test.py
@@ -57,7 +57,7 @@ class Foo(QObject):
self.s.emit(i)
-# PYSIDE-2201: This crashed until we introduced a weak reference.
+# PYSIDE-2201/2328: This crashed until we introduced a weak reference.
class TestDestroyNoConnect(unittest.TestCase):
def testSignalDestroyedMissingReference(self):
@@ -67,6 +67,11 @@ class TestDestroyNoConnect(unittest.TestCase):
with self.assertRaises(RuntimeError):
Foo().s.emit(44)
+ def testSignalDestroyedinConnect(self):
+ # PYSIDE-2328: Connect to signal of temporary
+ with self.assertRaises(RuntimeError):
+ Foo().s.connect(None)
+
if __name__ == '__main__':
unittest.main()