fix test runs

This commit is contained in:
Daniel Knopik
2026-04-30 09:16:58 +02:00
parent bbffb80612
commit ae17107f78
2 changed files with 10 additions and 8 deletions

View File

@@ -878,10 +878,7 @@ impl<E: EthSpec> AvailableBlock<E> {
match &block_data {
AvailableBlockData::NoData => {
// For Gloas, DA is checked for the PayloadEnvelope, not for the block.
if block.fork_name(&spec).map_err(|_| {
AvailabilityCheckError::Unexpected("Unexpected fork mismatch".to_string())
})? < ForkName::Gloas
{
if block.fork_name_unchecked() < ForkName::Gloas {
if columns_required {
return Err(AvailabilityCheckError::MissingCustodyColumns);
} else if blobs_required {

View File

@@ -549,12 +549,18 @@ mod tests {
#[test]
fn no_blobs_into_responses() {
let spec = Arc::new(test_spec::<E>());
let mut rng = XorShiftRng::from_seed([42; 16]);
let blocks = (0..4)
.map(|_| {
generate_rand_block_and_blobs::<E>(ForkName::Base, NumBlobs::None, &mut rng)
.0
.into()
generate_rand_block_and_blobs::<E>(
spec.fork_name_at_epoch(Epoch::new(0)),
NumBlobs::None,
&mut rng,
)
.0
.into()
})
.collect::<Vec<Arc<SignedBeaconBlock<E>>>>();
@@ -565,7 +571,6 @@ mod tests {
// Send blocks and complete terminate response
info.add_blocks(blocks_req_id, blocks).unwrap();
let spec = Arc::new(test_spec::<E>());
let da_checker = Arc::new(test_da_checker(spec.clone(), NodeCustodyType::Fullnode));
// Assert response is finished and RpcBlocks can be constructed