mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
Whitespace normalization.
This commit is contained in:
parent
6b95f1d963
commit
5d36a55eaa
4 changed files with 174 additions and 174 deletions
|
@ -78,26 +78,26 @@ class FloatTestCase(unittest.TestCase):
|
|||
self.assertEqual(f, got)
|
||||
# and with version <= 1 (floats marshalled differently then)
|
||||
s = marshal.dumps(f, 1)
|
||||
got = marshal.loads(s)
|
||||
self.assertEqual(f, got)
|
||||
got = marshal.loads(s)
|
||||
self.assertEqual(f, got)
|
||||
|
||||
n = sys.maxint * 3.7e-250
|
||||
while n < small:
|
||||
for expected in (-n, n):
|
||||
f = float(expected)
|
||||
|
||||
|
||||
s = marshal.dumps(f)
|
||||
got = marshal.loads(s)
|
||||
self.assertEqual(f, got)
|
||||
|
||||
|
||||
s = marshal.dumps(f, 1)
|
||||
got = marshal.loads(s)
|
||||
self.assertEqual(f, got)
|
||||
|
||||
|
||||
marshal.dump(f, file(test_support.TESTFN, "wb"))
|
||||
got = marshal.load(file(test_support.TESTFN, "rb"))
|
||||
self.assertEqual(f, got)
|
||||
|
||||
|
||||
marshal.dump(f, file(test_support.TESTFN, "wb"), 1)
|
||||
got = marshal.load(file(test_support.TESTFN, "rb"))
|
||||
self.assertEqual(f, got)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue