mirror of
https://github.com/logos-blockchain/logos-blockchain-specs.git
synced 2026-02-05 22:03:12 +00:00
Fix test
This commit is contained in:
parent
e54d535081
commit
fd1f92e12d
@ -18,12 +18,11 @@ class TestFK20(TestCase):
|
||||
)
|
||||
|
||||
def test_fk20(self):
|
||||
for size in [16, 32, 64, 128]:
|
||||
roots_of_unity = compute_roots_of_unity(PRIMITIVE_ROOT, size*2, BLS_MODULUS)
|
||||
for size in [16, 32, 64, 128, 256]:
|
||||
roots_of_unity = compute_roots_of_unity(PRIMITIVE_ROOT, size, BLS_MODULUS)
|
||||
rand_bytes = self.rand_bytes(size)
|
||||
polynomial = bytes_to_polynomial(rand_bytes)
|
||||
proofs = [generate_element_proof(i, polynomial, GLOBAL_PARAMETERS, roots_of_unity) for i in range(size)]
|
||||
fk20_proofs = fk20_generate_proofs(polynomial, GLOBAL_PARAMETERS)
|
||||
self.assertEqual(len(proofs), len(fk20_proofs))
|
||||
self.assertEqual(proofs, fk20_proofs)
|
||||
|
||||
|
||||
@ -1,5 +1,4 @@
|
||||
|
||||
POWERS_OF_2 = {2**i for i in range(1, 8)}
|
||||
POWERS_OF_2 = {2**i for i in range(1, 32)}
|
||||
|
||||
|
||||
def is_power_of_two(n) -> bool:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user