mirror of
https://github.com/python/cpython.git
synced 2025-12-04 00:30:19 +00:00
convert usage of fail* to assert*
This commit is contained in:
parent
be96cf608f
commit
5c8da86f3a
268 changed files with 5017 additions and 5017 deletions
|
|
@ -30,15 +30,15 @@ class XDRTest(unittest.TestCase):
|
|||
|
||||
self.assertEqual(up.unpack_int(), 42)
|
||||
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)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue