Skip to content

Commit

Permalink
changes per feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
StefanBratanov committed May 17, 2023
1 parent a56139c commit 2c2c6f4
Showing 1 changed file with 8 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,19 +20,14 @@
import tech.pegasys.teku.infrastructure.json.JsonUtil;
import tech.pegasys.teku.infrastructure.json.types.DeserializableOneOfTypeDefinition;
import tech.pegasys.teku.spec.Spec;
import tech.pegasys.teku.spec.SpecMilestone;
import tech.pegasys.teku.spec.TestSpecFactory;
import tech.pegasys.teku.spec.datastructures.blobs.versions.deneb.BlindedBlobSidecarSchema;
import tech.pegasys.teku.spec.datastructures.blobs.versions.deneb.BlobSchema;
import tech.pegasys.teku.spec.datastructures.blobs.versions.deneb.BlobSidecarSchema;
import tech.pegasys.teku.spec.datastructures.blobs.versions.deneb.SignedBlindedBlobSidecarSchema;
import tech.pegasys.teku.spec.datastructures.blobs.versions.deneb.SignedBlobSidecarSchema;
import tech.pegasys.teku.spec.datastructures.blocks.SignedBeaconBlock;
import tech.pegasys.teku.spec.datastructures.blocks.SignedBlindedBlockContainer;
import tech.pegasys.teku.spec.datastructures.blocks.SignedBlockContainer;
import tech.pegasys.teku.spec.datastructures.blocks.versions.deneb.SignedBlindedBlockContents;
import tech.pegasys.teku.spec.datastructures.blocks.versions.deneb.SignedBlindedBlockContentsSchema;
import tech.pegasys.teku.spec.datastructures.blocks.versions.deneb.SignedBlockContents;
import tech.pegasys.teku.spec.datastructures.blocks.versions.deneb.SignedBlockContentsSchema;
import tech.pegasys.teku.spec.schemas.SchemaDefinitionsDeneb;
import tech.pegasys.teku.spec.util.DataStructureUtil;

public class DeserializeBlocksTest {
Expand All @@ -52,13 +47,9 @@ public class DeserializeBlocksTest {
.withType(
SignedBlockContents.isSignedBlockContentsInstance,
s -> s.contains("blob_sidecars"),
SignedBlockContentsSchema.create(
spec.getGenesisSpecConfig().toVersionDeneb().orElseThrow(),
SignedBlobSidecarSchema.create(
BlobSidecarSchema.create(
new BlobSchema(
spec.getGenesisSpecConfig().toVersionDeneb().orElseThrow()))),
spec.getGenesisSchemaDefinitions().getSignedBeaconBlockSchema())
SchemaDefinitionsDeneb.required(
spec.forMilestone(SpecMilestone.DENEB).getSchemaDefinitions())
.getSignedBlockContentsSchema()
.getJsonTypeDefinition())
.build();

Expand All @@ -76,10 +67,9 @@ public class DeserializeBlocksTest {
.withType(
SignedBlindedBlockContents.isSignedBlindedBlockContentsInstance,
s -> s.contains("blob_sidecars"),
SignedBlindedBlockContentsSchema.create(
spec.getGenesisSpecConfig().toVersionDeneb().orElseThrow(),
SignedBlindedBlobSidecarSchema.create(BlindedBlobSidecarSchema.create()),
spec.getGenesisSchemaDefinitions().getSignedBeaconBlockSchema())
SchemaDefinitionsDeneb.required(
spec.forMilestone(SpecMilestone.DENEB).getSchemaDefinitions())
.getSignedBlindedBlockContentsSchema()
.getJsonTypeDefinition())
.build();

Expand Down

0 comments on commit 2c2c6f4

Please sign in to comment.