From e3b24c2204fedb0141ddd949e4f556d345780df1 Mon Sep 17 00:00:00 2001 From: Hugo Parente Lima Date: Wed, 6 Apr 2011 15:59:01 -0300 Subject: Fix 720 - "QByteArray prints itself wrong, on tp_print and tp_repr" Reviewer: Luciano Wolf Marcelo Lira --- tests/QtCore/qbytearray_test.py | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tests/QtCore') diff --git a/tests/QtCore/qbytearray_test.py b/tests/QtCore/qbytearray_test.py index 4a600ba31..330a7d09f 100644 --- a/tests/QtCore/qbytearray_test.py +++ b/tests/QtCore/qbytearray_test.py @@ -148,6 +148,12 @@ class TestPickler(unittest.TestCase): ba2 = pickle.loads(output.getvalue()) self.assertEqual(ba, ba2) +class QByteArrayBug720(unittest.TestCase): + def testIt(self): + ba = QByteArray("32\"1\x00123") + self.assertEqual(str(ba), "32\"1\x00123") + self.assertEqual(repr(ba), "PySide.QtCore.QByteArray(\"32\\\"1\x00123\")") + if __name__ == '__main__': unittest.main() -- cgit v1.2.3