check generated id in test_vdf_create
This commit is contained in:
parent
3a96c16282
commit
5aada78747
@ -9,12 +9,14 @@ from math import floor
|
||||
class TestAnonVDF(unittest.TestCase):
|
||||
def test_vdf_create(self):
|
||||
test_data = kasten.generator.pack.pack(b"test", "tst", 0)
|
||||
test_vdf = mimcvdf.vdf_create(test_data, 1000)
|
||||
test_vdf = mimcvdf.vdf_create(test_data, 1000, dec=True)
|
||||
|
||||
generated = anonvdf.AnonVDFGenerator.generate(test_data, rounds=1000)
|
||||
self.assertEqual(
|
||||
anonvdf.AnonVDFGenerator.generate(test_data, rounds=1000).get_packed(),
|
||||
generated.get_packed(),
|
||||
test_data
|
||||
)
|
||||
self.assertEqual(generated.id, int(test_vdf).to_bytes(64, byteorder="big"))
|
||||
|
||||
def test_vdf_block_validate_ok_time(self):
|
||||
rds = 8000
|
||||
|
Loading…
Reference in New Issue
Block a user