This commit is contained in:
Maximilian Hils 2022-09-15 14:06:09 +02:00
parent b78869b584
commit 780adbaf9b
1 changed files with 2 additions and 1 deletions

View File

@ -87,7 +87,8 @@ class Test_Format(unittest.TestCase):
self.assertEqual((v, b""), tnetstring.pop(tnetstring.dumps(v))) self.assertEqual((v, b""), tnetstring.pop(tnetstring.dumps(v)))
def test_roundtrip_big_integer(self): def test_roundtrip_big_integer(self):
i1 = math.factorial(30000) # Recent Python versions do not like ints above 4300 digits, https://github.com/python/cpython/issues/95778
i1 = math.factorial(1557)
s = tnetstring.dumps(i1) s = tnetstring.dumps(i1)
i2 = tnetstring.loads(s) i2 = tnetstring.loads(s)
self.assertEqual(i1, i2) self.assertEqual(i1, i2)