diff options
Diffstat (limited to 'Lib/test/test_xdrlib.py')
-rw-r--r-- | Lib/test/test_xdrlib.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/Lib/test/test_xdrlib.py b/Lib/test/test_xdrlib.py index 8fc88a5f2e..9ba8885c0a 100644 --- a/Lib/test/test_xdrlib.py +++ b/Lib/test/test_xdrlib.py @@ -12,6 +12,7 @@ class XDRTest(unittest.TestCase): a = ['what', 'is', 'hapnin', 'doctor'] p.pack_int(42) + p.pack_int(-17) p.pack_uint(9) p.pack_bool(True) p.pack_bool(False) @@ -29,16 +30,17 @@ class XDRTest(unittest.TestCase): self.assertEqual(up.get_position(), 0) self.assertEqual(up.unpack_int(), 42) + self.assertEqual(up.unpack_int(), -17) self.assertEqual(up.unpack_uint(), 9) - self.assert_(up.unpack_bool() is True) + self.assertTrue(up.unpack_bool() is True) # remember position pos = up.get_position() - self.assert_(up.unpack_bool() is False) + self.assertTrue(up.unpack_bool() is False) # rewind and unpack again up.set_position(pos) - self.assert_(up.unpack_bool() is False) + self.assertTrue(up.unpack_bool() is False) self.assertEqual(up.unpack_uhyper(), 45L) self.assertAlmostEqual(up.unpack_float(), 1.9) |