lighthouse
lighthouse copied to clipboard
Add tests for EIP 7549
Issue Addressed
Expand Electra attestation test suite
Proposed Changes
This PR adds comprehensive test coverage for Electra attestations, focusing on equivalence with base attestations and multi-committee functionality. Added tests include:
- Basic Creation Equivalence Test:
#[test]
fn test_creation_equivalence() {
// Verifies that Electra attestations maintain equivalent basic properties
// with Base attestations while supporting committee tracking
}
- Signature Verification:
#[test]
fn test_signature_equivalence() {
// Ensures signature creation and verification work identically
// between Base and Electra attestations
}
- Aggregation Testing:
#[test]
fn test_aggregation_equivalence() {
// Validates that aggregation behavior matches between
// Base and Electra attestations
}
- Error Handling:
#[test]
fn test_error_handling_equivalence() {
// Confirms error conditions are handled consistently
// across both attestation types
}
- Multi-Committee Support:
#[test]
fn test_multi_committee_aggregation() {
// Tests Electra's unique ability to handle multiple committees
// in a single attestation
}
Additional Info
Test Coverage Focus
- Base vs Electra equivalence for backward compatibility
- Multi-committee functionality specific to Electra
- Edge cases in signature aggregation
- Error handling consistency
Testing Notes
- Uses
create_test_data()helper for consistent test scenarios - Explicitly tests both single and multi-committee cases
- Verifies bit manipulation for committee tracking
- Ensures proper index translation between committee spaces
Review Considerations
- Pay special attention to the multi-committee test cases
- Verify error handling matches existing behavior
- Check signature aggregation correctness
- Confirm committee bit manipulation is correct
Some required checks have failed. Could you please take a look @bshastry? 🙏
Hi @bshastry, this pull request has been closed automatically due to 30 days of inactivity. If you’d like to continue working on it, feel free to reopen at any time.