Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(rebuild): functions with unit tests #105

Merged
merged 56 commits into from Jan 5, 2024

Conversation

matthewkeil
Copy link
Member

@matthewkeil matthewkeil commented Jun 21, 2023

Sync and Async version of rebuilt functions. No helper classes were used.

How to test

cd rebuild
yarn
yarn test:unit

@matthewkeil matthewkeil changed the title Mkeil/rebuild sync functions feat(rebuild): functions with unit tests Jun 22, 2023
@matthewkeil matthewkeil marked this pull request as ready for review June 22, 2023 09:08
@matthewkeil matthewkeil requested a review from a team as a code owner June 22, 2023 09:08
@matthewkeil matthewkeil marked this pull request as draft June 22, 2023 18:03
@matthewkeil matthewkeil removed the request for review from a team June 22, 2023 18:03
rebuild/src/functions.cc Outdated Show resolved Hide resolved
rebuild/src/functions.cc Outdated Show resolved Hide resolved
rebuild/src/functions.h Outdated Show resolved Hide resolved
rebuild/src/functions.h Outdated Show resolved Hide resolved
});
it("should be able to keyValidate PublicKey", () => {
const agg = aggregatePublicKeys(keys);
expect(agg.keyValidate()).to.be.undefined;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

key validate would through on invalid ? in that case check for not throw

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is impossible to deserialize an invalid PublicKey with the blst library. It will throw when creating the point before aggregation. I added an error check for invalid key though. Will that work?

@matthewkeil matthewkeil changed the base branch from mkeil/rebuild-sync-pki to mkeil/rebuild January 5, 2024 18:53
feat(rebuild): fixes from implementation into lodestar
@matthewkeil matthewkeil merged commit 2a25955 into mkeil/rebuild Jan 5, 2024
1 check passed
@matthewkeil matthewkeil deleted the mkeil/rebuild-sync-functions branch April 22, 2024 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants