diff --git a/tests/core/pyspec/eth2spec/test/phase0/unittests/math/test_integer_squareroot.py b/tests/core/pyspec/eth2spec/test/phase0/unittests/math/test_integer_squareroot.py index 988de1657c..159f3c9b94 100644 --- a/tests/core/pyspec/eth2spec/test/phase0/unittests/math/test_integer_squareroot.py +++ b/tests/core/pyspec/eth2spec/test/phase0/unittests/math/test_integer_squareroot.py @@ -21,3 +21,9 @@ def test_integer_squareroot(spec): n = rng.randint(0, 2**64 - 1) uint64_n = spec.uint64(n) assert spec.integer_squareroot(uint64_n) == isqrt(n) + + try: + spec.integer_squareroot(spec.uint64(2**64)) + assert False + except ValueError: + pass