-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Aggregator Consensus data with no justifications #332
Closed
GalRogozinski
wants to merge
4
commits into
ssvlabs:main
from
GalRogozinski:aggregator_no_justifications
Closed
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/aggregator_justifications.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// AggregatorJustifications tests a valid consensus data with aggregator pre-consensus justifications | ||
func AggregatorJustifications() *SpecTest { | ||
func AggregatorJustifications() tests.SpecTest { | ||
panic("implement") | ||
} |
26 changes: 23 additions & 3 deletions
26
types/spectest/tests/consensusdata/aggregator_no_justifications.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,26 @@ | ||
package consensusdata | ||
|
||
// AggregatorNoJustifications tests an invalid consensus data with no aggregator pre-consensus justifications | ||
func AggregatorNoJustifications() *SpecTest { | ||
panic("implement") | ||
import ( | ||
"github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
"github.com/bloxapp/ssv-spec/types/testingutils" | ||
) | ||
|
||
// AggregatorNoJustifications tests consensus data with no aggregator pre-consensus justifications | ||
func AggregatorNoJustifications() tests.SpecTest { | ||
cd := testingutils.TestAggregatorConsensusData | ||
|
||
byts, err := cd.Encode() | ||
if err != nil { | ||
panic(err.Error()) | ||
} | ||
root, err := cd.HashTreeRoot() | ||
if err != nil { | ||
panic(err.Error()) | ||
} | ||
|
||
return &EncodingTest{ | ||
Name: "consensusdata aggregator no justifications encoding", | ||
Data: byts, | ||
ExpectedRoot: root, | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// AggregatorValidation tests a valid consensus data with AggregateAndProof | ||
func AggregatorValidation() *SpecTest { | ||
func AggregatorValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// AttestationValidation tests a valid consensus data with AttestationData | ||
func AttestationValidation() *SpecTest { | ||
func AttestationValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// AttesterJustifications tests an invalid consensus data with attester pre-consensus justifications | ||
func AttesterJustifications() *SpecTest { | ||
func AttesterJustifications() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/attester_no_justifications.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// AttesterNoValidation tests a valid attester consensus data with no pre-consensus justifications | ||
func AttesterNoValidation() *SpecTest { | ||
func AttesterNoValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/capella_blinded_block_validation.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// CapellaBlindedBlockValidation tests a valid consensus data with capella blinded block | ||
func CapellaBlindedBlockValidation() *SpecTest { | ||
func CapellaBlindedBlockValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/capella_block_validation.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// CapellaBlockValidation tests a valid consensus data with capella block | ||
func CapellaBlockValidation() *SpecTest { | ||
func CapellaBlockValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// ConsensusDataEncoding tests encoding and decoding ConsensusData for all duties | ||
func ConsensusDataEncoding() *SpecTest { | ||
func ConsensusDataEncoding() tests.SpecTest { | ||
panic("implement") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// ContributionsEncoding tests encoding and decoding contributions | ||
func ContributionsEncoding() *SpecTest { | ||
func ContributionsEncoding() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/invalid_aggregator_validation.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// InvalidAggregatorValidation tests an invalid consensus data with AggregateAndProof | ||
func InvalidAggregatorValidation() *SpecTest { | ||
func InvalidAggregatorValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/invalid_attestation_validation.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// InvalidAttestationValidation tests an invalid consensus data with AttestationData | ||
func InvalidAttestationValidation() *SpecTest { | ||
func InvalidAttestationValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/invalid_capella_blinded_block_validation.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// InvalidCapellaBlindedBlockValidation tests an invalid consensus data with capella blinded block | ||
func InvalidCapellaBlindedBlockValidation() *SpecTest { | ||
func InvalidCapellaBlindedBlockValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/invalid_capella_block_validation.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// InvalidCapellaBlockValidation tests an invalid consensus data with capella block | ||
func InvalidCapellaBlockValidation() *SpecTest { | ||
func InvalidCapellaBlockValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/invalid_sync_committee_block_validation.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// InvalidSyncCommitteeBlockValidation tests an invalid consensus data with sync committee block data. | ||
func InvalidSyncCommitteeBlockValidation() *SpecTest { | ||
func InvalidSyncCommitteeBlockValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/invalid_sync_committee_cntribution_validation.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// InvalidSyncCommitteeContributionValidation tests an invalid consensus data with sync committee contrib. | ||
func InvalidSyncCommitteeContributionValidation() *SpecTest { | ||
func InvalidSyncCommitteeContributionValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// ProposerJustifications tests a valid consensus data with proposer justifications | ||
func ProposerJustifications() *SpecTest { | ||
func ProposerJustifications() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/proposer_no_justifications.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// ProposerNoJustifications tests an invalid consensus data with no proposer justifications | ||
func ProposerNoJustifications() *SpecTest { | ||
func ProposerNoJustifications() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/sync_committee_cntribution_validation.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// SyncCommitteeContributionValidation tests a valid consensus data with sync committee contrib. | ||
func SyncCommitteeContributionValidation() *SpecTest { | ||
func SyncCommitteeContributionValidation() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/sync_committee_contrib_justifications.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// SyncCommitteeContributionJustifications tests a valid consensus data with sync committee contribution pre-consensus justifications | ||
func SyncCommitteeContributionJustifications() *SpecTest { | ||
func SyncCommitteeContributionJustifications() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/sync_committee_justifications.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// SyncCommitteeJustifications tests an invalid consensus data with sync committee pre-consensus justifications | ||
func SyncCommitteeJustifications() *SpecTest { | ||
func SyncCommitteeJustifications() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/sync_committee_no_contrib_justifications.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// SyncCommitteeNoContributionJustifications tests an invalid consensus data with no sync committee contribution pre-consensus justifications | ||
func SyncCommitteeNoContributionJustifications() *SpecTest { | ||
func SyncCommitteeNoContributionJustifications() tests.SpecTest { | ||
panic("implement") | ||
} |
4 changes: 3 additions & 1 deletion
4
types/spectest/tests/consensusdata/sync_committee_no_justifications.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// SyncCommitteeNoJustifications tests a valid consensus data with no sync committee pre-consensus justifications | ||
func SyncCommitteeNoJustifications() *SpecTest { | ||
func SyncCommitteeNoJustifications() tests.SpecTest { | ||
panic("implement") | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package consensusdata | ||
|
||
import "github.com/bloxapp/ssv-spec/types/spectest/tests" | ||
|
||
// ValidatorRegistration tests an invalid consensus data for validator registration (has no consensus data) | ||
func ValidatorRegistration() *SpecTest { | ||
func ValidatorRegistration() tests.SpecTest { | ||
panic("implement") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package tests | ||
|
||
import "testing" | ||
|
||
type SpecTest interface { | ||
TestName() string | ||
Run(t *testing.T) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that it is no issue to have an empty pre-con justification field here