Skip to content

Conversation

@casks-mutters
Copy link
Owner

Summary

Currently, there are no tests for the leaf_commitment and pair_root functions. Adding tests will help ensure the correctness of these core functions.

Proposed Changes

  • Create a new tests/ directory.
  • Add unit tests for:
    • leaf_commitment: check that the correct commitment is returned for a given slot, address, and block.
    • pair_root: verify that it correctly computes the root from two leaf values.

Motivation

  • Provides confidence that the core cryptographic functions behave as expected.
  • Helps detect regressions or incorrect changes in the future.

## Summary

Currently, there are no tests for the `leaf_commitment` and `pair_root` functions. Adding tests will help ensure the correctness of these core functions.

## Proposed Changes

- Create a new `tests/` directory.
- Add unit tests for:
  - `leaf_commitment`: check that the correct commitment is returned for a given slot, address, and block.
  - `pair_root`: verify that it correctly computes the root from two leaf values.
  
## Motivation

- Provides confidence that the core cryptographic functions behave as expected.  
- Helps detect regressions or incorrect changes in the future.
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.

2 participants