Skip to content

Commit

Permalink
update test random impl for attestation
Browse files Browse the repository at this point in the history
  • Loading branch information
eserilev committed Apr 15, 2024
1 parent cf9ecda commit 84c0d99
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions beacon_node/beacon_chain/tests/attestation_verification.rs
Original file line number Diff line number Diff line change
Expand Up @@ -717,6 +717,7 @@ async fn aggregated_gossip_verification() {
"aggregate with unknown aggregator index",
|_, a| a.message.aggregator_index = VALIDATOR_COUNT as u64,
|_, err| {
println!("{:?}", err);
assert!(matches!(
err,
// Naively we should think this condition would trigger this error:
Expand Down
4 changes: 2 additions & 2 deletions consensus/types/src/attestation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,9 @@ impl<E: EthSpec> TestRandom for Attestation<E> {
let data = AttestationData::random_for_test(rng);
let signature = AggregateSignature::random_for_test(rng);

Self::Electra(AttestationElectra {
Self::Base(AttestationBase {
aggregation_bits,
committee_bits,
// committee_bits,
data,
signature,
})
Expand Down
4 changes: 2 additions & 2 deletions consensus/types/src/pending_attestation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,9 @@ impl<E: EthSpec> TestRandom for PendingAttestation<E> {
let proposer_index = u64::random_for_test(rng);
let inclusion_delay = u64::random_for_test(rng);

Self::Electra(PendingAttestationElectra {
Self::Base(PendingAttestationBase {
aggregation_bits,
committee_bits,
// committee_bits,
data,
proposer_index,
inclusion_delay,
Expand Down

0 comments on commit 84c0d99

Please sign in to comment.