This repository has been archived on 2023-04-09. You can view files and clone it, but cannot push or open issues or pull requests.
chainsafe-bls/test/spec/priv_to_public.test.ts

15 lines
420 B
TypeScript

import {join} from "path";
import {describeSpecTest} from "@chainsafe/eth2.0-spec-test-util";
import bls from "../../src";
describeSpecTest(
join(__dirname, "../../../spec-test-cases/tests/bls/priv_to_pub/priv_to_pub.yaml"),
bls.generatePublicKey,
({input}) => {
return [Buffer.from(input.replace('0x', ''), 'hex')];
},
({output}) => output,
(result) => `0x${result.toString('hex')}`,
() => false,
);