diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/QtGui/qcolor_test.py | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/tests/QtGui/qcolor_test.py b/tests/QtGui/qcolor_test.py index 29b0d5dbb..26f3f4cf7 100644 --- a/tests/QtGui/qcolor_test.py +++ b/tests/QtGui/qcolor_test.py @@ -3,7 +3,7 @@ import unittest import colorsys import PySide -from PySide.QtCore import Qt, qFuzzyCompare +from PySide.QtCore import Qt from PySide.QtGui import QColor @@ -69,6 +69,17 @@ class QColorCopy(unittest.TestCase): del original self.assertEqual(copy, QColor(0, 0, 255)) + def testEmptyCopy(self): + from copy import deepcopy + + original = QColor() + copy = deepcopy([original])[0] + self.assert_(original is not copy) + self.assertEqual(original, copy) + del original + self.assertEqual(copy, QColor()) + + class QColorRepr(unittest.TestCase): def testReprFunction(self): c = QColor(100, 120, 200) |