ChainSafe / blst-ts

Typescript wrapper for https://github.com/supranational/blst native bindings, a highly performant BLS12-381 signature library
Other
18 stars 13 forks source link

bug(fastAggregateVerify): issue rectifying specs for altair and phase0 #98

Closed matthewkeil closed 9 months ago

matthewkeil commented 1 year ago

This PR is related to #88 and covers spec testing of fatsAggregateVerify

_note: I was unable to rectify phase0/fast_aggregate_verify_na_pubkeys_and_infinity_signature and altair/eth_fast_aggregate_verify_na_pubkeys_and_infinity_signature with c. The spec tests for identical conditions that changed between forks. Without programmatic knowledge of the fork its not possible to return both true and false for the same conditions. I used the method in the existing spec tests of checking in the wrapper function that converts the spec name to the correct function here_

Inclusions

How to test

NOTE: to build and test copy the blst folder into rebuild/deps/blst. This will go away when we merge but for now node-gyp gets heartburn when building deps in folder above the binding.gyp file

Unit tests are provided and should have 100% coverage. If you see an edge that may not be covered please feel free to bring it up and I will add the test case

cd rebuild
yarn
yarn build
yarn test:unit
yarn test:spec
CLAassistant commented 1 year ago

CLA assistant check
All committers have signed the CLA.

matthewkeil commented 9 months ago

closed with preference for macros instead of class based constructs. see rebuild branch