Skip to content
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

ssz: fix ssv sanity tests #162

Merged
merged 152 commits into from
Mar 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
152 commits
Select commit Hold shift + click to select a range
51e16f1
Make tests compilable
nkryuchkov Feb 14, 2023
8ac46bf
Simplify futuremsg.Cleanup
nkryuchkov Feb 15, 2023
30ce7b4
Fix operator ID in `proposal.FutureRound`
nkryuchkov Feb 15, 2023
539b412
Merge branch 'ssz' into ssz-fix-tests
nkryuchkov Feb 15, 2023
dc8b6c9
Fix issues in roundchange.HappyFlow
nkryuchkov Feb 15, 2023
a519335
Fix issue `ks.Shares[2], types.OperatorID(2), 3` -> `ks.Shares[3], ty…
nkryuchkov Feb 15, 2023
58406aa
Fix WrongProposer
nkryuchkov Feb 15, 2023
b26a85b
Fix roundchange.AfterProposal
nkryuchkov Feb 15, 2023
379e9c0
Fix roundchange.RoundChangePartialQuorum
nkryuchkov Feb 15, 2023
ab651fb
Fix CommitDataInvalid
nkryuchkov Feb 15, 2023
51d7fd9
Fix prepare.UnknownSigner
nkryuchkov Feb 15, 2023
98635f9
Fix DuplicateMsgQuorumPreparedRCFirst
nkryuchkov Feb 15, 2023
32fe746
Fix proposal.FutureRound
nkryuchkov Feb 15, 2023
75b8433
Fix proposal.FutureRoundPrevNotPrepared
nkryuchkov Feb 15, 2023
93e0e66
Add a comment
nkryuchkov Feb 15, 2023
a0d7ba1
Fix tests.HappyFlow
nkryuchkov Feb 15, 2023
656a7dc
Fix tests.SevenOperators
nkryuchkov Feb 15, 2023
a367afc
Fix tests.TenOperators
nkryuchkov Feb 15, 2023
466472a
Fix tests.ThirteenOperators
nkryuchkov Feb 15, 2023
bbf04c7
Fix prepare.HappyFlow
nkryuchkov Feb 15, 2023
db50cef
Fix commit.HappyFlow
nkryuchkov Feb 15, 2023
d487c0b
Fix issues in generators of testing messages
nkryuchkov Feb 15, 2023
d875739
sanity tests
alonmuroch Feb 15, 2023
87f5c53
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
faae4df
WIP spec testsd
alonmuroch Feb 16, 2023
a6e1181
WIP base sanity tests
alonmuroch Feb 16, 2023
4241ef2
Use DecidingMsgsForHeight
nkryuchkov Feb 16, 2023
6a8e960
Set FullData for prepare multi signer message
nkryuchkov Feb 16, 2023
99dfd64
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
25f1531
Fix InputValue and DecidedVal in qbft controller spectests
nkryuchkov Feb 16, 2023
3d7e6bb
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
4c6a7d1
Fix proposal.CurrentRoundPrevPrepared()
nkryuchkov Feb 16, 2023
903e599
Fix proposal.PastRoundProposalPrevPrepared()
nkryuchkov Feb 16, 2023
524caa5
Revert "Fix InputValue and DecidedVal in qbft controller spectests"
nkryuchkov Feb 16, 2023
b5c8bf5
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
cb1ba96
Fix DecidedVal in controller/decided tests
nkryuchkov Feb 16, 2023
daef76c
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
62c99f2
Fix decided.HasQuorum()
nkryuchkov Feb 16, 2023
d236565
Fix decided.LateDecidedBiggerQuorum(), decided.LateDecidedSmallerQuor…
nkryuchkov Feb 16, 2023
aa5b078
Fix DecidedVal in NoInstanceRunning and LateCommit
nkryuchkov Feb 16, 2023
4f61dad
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
26f40d7
Fix proposal message in CurrentInstancePastRound
nkryuchkov Feb 16, 2023
b47d730
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
0f60a5d
Fix decided.CurrentInstancePastRound
nkryuchkov Feb 16, 2023
10c0afc
Fix decided.CurrentInstanceFutureRound
nkryuchkov Feb 16, 2023
0abaf85
Fix proposal message and decided value in latemsg.LateCommitPastRound
nkryuchkov Feb 16, 2023
e770b84
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
ea828c1
Fix startinstance.EmptyValue, startinstance.NilValue, startinstance.V…
nkryuchkov Feb 16, 2023
b85bd2d
Fix processmsg.NoInstanceRunning()
nkryuchkov Feb 16, 2023
6c4231f
Fix latemsg.LateCommit()
nkryuchkov Feb 16, 2023
ab61ad3
Fix latemsg.LateCommitPastRound()
nkryuchkov Feb 16, 2023
e73ef7f
Fix signers in proposal.FutureRoundPrevNotPrepared
nkryuchkov Feb 16, 2023
3c351bd
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
660818c
Fix:
nkryuchkov Feb 16, 2023
49f0cca
Set FullData when creating testing round change message
nkryuchkov Feb 16, 2023
cf20f08
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 16, 2023
ef5ceb4
Fix proposal: CurrentRoundPrevPrepared, FutureRound, FutureRoundPrevN…
nkryuchkov Feb 16, 2023
90a45b0
Update roots for controller tests
nkryuchkov Feb 16, 2023
78949a0
Remove PreparedPreviouslyJustificationDebug
nkryuchkov Feb 16, 2023
5b2382a
Change start value for qbft base instance to TestingQBFTFullData
nkryuchkov Feb 17, 2023
85dddcf
Adjust round change message in roundchange.HappyFlow
nkryuchkov Feb 17, 2023
bec5f10
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 17, 2023
c6eb9f8
Fix roundchange.HappyFlow
nkryuchkov Feb 17, 2023
93e87c4
Fix output message in roundchange.F1Speedup
nkryuchkov Feb 17, 2023
ee3229f
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 17, 2023
53465f7
Fix round change messages in roundchange.F1SpeedupPrevPrepared and ro…
nkryuchkov Feb 17, 2023
72e14b6
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 17, 2023
d18ee68
Fix roots in remaining sanity round change tests
nkryuchkov Feb 17, 2023
17e36d0
Fix issues in sanity futuremsg tests
nkryuchkov Feb 17, 2023
bc02fc9
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 17, 2023
ead28f5
Fix remaining sanity futuremsg tests
nkryuchkov Feb 17, 2023
bf588da
Add proposal.InvalidFullData test
nkryuchkov Feb 17, 2023
33fc8b8
Fix root in proposal.CurrentRoundPrevNotPrepared
nkryuchkov Feb 17, 2023
7220425
Fix checks if H(data) != root
nkryuchkov Feb 17, 2023
ca6aff4
Fix signers in startinstance.PostFutureDecided
nkryuchkov Feb 17, 2023
f86b1be
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 17, 2023
0178aff
remove full data on marshaling justifications + tests
alonmuroch Feb 19, 2023
f43c28e
fix test import cycle
aaron-blox Feb 19, 2023
e993c3c
fix linting
aaron-blox Feb 19, 2023
d9d7780
partial sig slot validation + tests
alonmuroch Feb 19, 2023
b194609
ssv full happy flow spec passes
alonmuroch Feb 19, 2023
55db1b2
Merge pull request #160 from bloxapp/ssz-test-import-cycle
aaron-blox Feb 20, 2023
a6a8d6d
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 20, 2023
e5bb32f
Merge pull request #159 from bloxapp/ssz-fix-data-hash-checks
aaron-blox Feb 20, 2023
3200844
Remove irrelevant tests
nkryuchkov Feb 20, 2023
9a7760d
Remove irrelevant tests [2]
nkryuchkov Feb 20, 2023
a6e1ea1
Fix futuremsg.InvalidMsg
nkryuchkov Feb 20, 2023
c86a151
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 20, 2023
ae8b56f
Fix processmsg.InvalidIdentifier
nkryuchkov Feb 20, 2023
58b19bb
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 20, 2023
b6f6d7a
Remove irrelevant tests [3]
nkryuchkov Feb 20, 2023
d38985d
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 20, 2023
59cf4bd
Remove irrelevant tests [4]
nkryuchkov Feb 20, 2023
858da38
Fix round change message validation for MsgSpecTest type
nkryuchkov Feb 20, 2023
83e2bb6
Remove messages.RoundChangeDataInvalidPreparedValue
nkryuchkov Feb 20, 2023
c183716
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 20, 2023
508d85f
Fix issues with DecidedVal and lack of RC justifications in latemsg t…
nkryuchkov Feb 20, 2023
7ab64cd
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 20, 2023
376b5e5
Fix some startinstance and processmsg tests
nkryuchkov Feb 21, 2023
075c07e
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 21, 2023
643019f
Add a TODO to check InvalidRoundChangeJustificationPrepared test
nkryuchkov Feb 21, 2023
9043cdc
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 21, 2023
876b8ab
validRoundChange->validRoundChangeForData
alonmuroch Feb 21, 2023
fff2f37
Merge branch 'ssz-fix-tests' into ssz-fix-failing-tests
nkryuchkov Feb 21, 2023
e50978a
Fix roots of some tests; fix missing justification in some proposal t…
nkryuchkov Feb 21, 2023
007829e
Merge branch 'ssz' into ssz-fix-failing-tests
nkryuchkov Feb 21, 2023
2def9f9
Fix issues after merging
nkryuchkov Feb 21, 2023
fb32e2b
Uncomment sanity tests
nkryuchkov Feb 21, 2023
6a3078c
Remove duplicated sanity tests
nkryuchkov Feb 21, 2023
9dd72c1
Fix a comment in proposal.InvalidFullData
nkryuchkov Feb 21, 2023
277442d
Create helper functions receiving identifiers for all futuremsg tests
nkryuchkov Feb 22, 2023
d7cb3f5
Remove duplicated tests
nkryuchkov Feb 22, 2023
6a79508
Fix root for NotPreparedPreviouslyJustification
nkryuchkov Feb 22, 2023
2a2aa09
Fix timeout tests
nkryuchkov Feb 22, 2023
ba11c1a
Fix justification validation for MsgSpecTest
nkryuchkov Feb 22, 2023
cb9f455
Simplify identifier usage in testingutils
nkryuchkov Feb 22, 2023
0f6f283
Delete messages.RoundChangeDataInvalidPreparedRound()
nkryuchkov Feb 22, 2023
2fb7e1e
Remove messages.SignedMsgSigTooLong and messages.SignedMsgSigTooShort
nkryuchkov Feb 22, 2023
9de2afe
Rename testing variables
nkryuchkov Feb 22, 2023
43de360
Fix generating proposal message with different root and proposal.Dupl…
nkryuchkov Feb 22, 2023
8776904
Mark tests that have issues other that different instance roots with …
nkryuchkov Feb 22, 2023
6c51211
Remove outdated TODO from startinstance.PostFutureDecided
nkryuchkov Feb 22, 2023
73af49a
Update TODO comments
nkryuchkov Feb 22, 2023
028fcc6
Comment out accidentally uncommented tests
nkryuchkov Feb 22, 2023
eb16272
Fix proposal.PreparedPreviouslyNoPrepareJustificationQuorum
nkryuchkov Feb 22, 2023
2f0faea
Fix proposal.InvalidPrepareJustificationValue
nkryuchkov Feb 22, 2023
881b409
Fix proposal.InvalidPrepareJustificationRound
nkryuchkov Feb 22, 2023
a6db649
Delete commit.InvalidCommitData and prepare.InvalidPrepareData
nkryuchkov Feb 22, 2023
3accaaa
Mark decided.CurrentInstancePastRound and decided.CurrentInstanceFutu…
nkryuchkov Feb 22, 2023
16d8e42
Fix decided.CurrentInstance
nkryuchkov Feb 22, 2023
1be4987
Delete roundchange.JustificationInvalidPrepareData
nkryuchkov Feb 22, 2023
31862a5
Delete roundchange.JustificationWrongValue
nkryuchkov Feb 22, 2023
4319f50
Fix decided.CurrentInstance root
nkryuchkov Feb 22, 2023
4eacf49
Remove roundchange.InvalidRoundChangeData
nkryuchkov Feb 22, 2023
4743782
Merge branch 'ssz' into ssz-fix-remaining-tests-issues
nkryuchkov Feb 22, 2023
5d0fc41
Fix issues in remaining round change tests
nkryuchkov Feb 23, 2023
66ee7eb
Fix decided.InvalidValCheckData
nkryuchkov Feb 23, 2023
5bf5bdf
Mark decided.InvalidValCheckData as fixed
nkryuchkov Feb 23, 2023
64f84a7
Mark recently fixed round change tests as fixed
nkryuchkov Feb 23, 2023
62edf10
Delete proposal.JustificationsValueNotJustified
nkryuchkov Feb 23, 2023
7e48b57
Fix ssv sanity tests
nkryuchkov Feb 27, 2023
6235332
Remove debug print
nkryuchkov Feb 28, 2023
1d3717b
Fix DecidingMsgsForHeight
nkryuchkov Mar 1, 2023
c6ec2c5
Fix returned error if no running duty on consensus message processing
nkryuchkov Mar 1, 2023
5a5604d
Fix consensus.PostFinish test
nkryuchkov Mar 1, 2023
737af90
Delete messages.RoundChangeDataInvalidJustifications
nkryuchkov Mar 6, 2023
7cded3e
Attempt to fix consensus.PostFinish
nkryuchkov Mar 6, 2023
d37ea3a
Revert roundchange.JustificationWrongValue removal
nkryuchkov Mar 6, 2023
375ae07
Revert roundchange.JustificationWrongValue removal in all_tests.go
nkryuchkov Mar 6, 2023
20dd7bd
Fix roundchange.JustificationWrongValue
nkryuchkov Mar 6, 2023
97fe800
Comment out roundchange.JustificationWrongValue
nkryuchkov Mar 6, 2023
27b5140
Fix consensus.NoRunningDuty
nkryuchkov Mar 6, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 2 additions & 11 deletions qbft/spectest/all_tests.go
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ var AllTests = []SpecTest{
//startinstance.Valid(),
//startinstance.EmptyValue(),
//startinstance.NilValue(),
////startinstance.PostFutureDecided(), // TODO: fix panic
//startinstance.PostFutureDecided(),
//startinstance.FirstHeight(),
//startinstance.PreviousDecided(),
//startinstance.PreviousNotDecided(),
Expand All @@ -145,8 +145,6 @@ var AllTests = []SpecTest{
//proposer.TenOperators(),
//proposer.ThirteenOperators(),
//
//messages.RoundChangeDataInvalidJustifications(),
//messages.RoundChangeDataInvalidPreparedRound(),
//messages.RoundChangePrePreparedJustifications(),
//messages.RoundChangeNotPreparedJustifications(),
//messages.CommitDataEncoding(),
Expand All @@ -155,8 +153,6 @@ var AllTests = []SpecTest{
//messages.MsgTypeUnknown(),
//messages.PrepareDataEncoding(),
//messages.ProposeDataEncoding(),
//messages.SignedMsgSigTooShort(),
//messages.SignedMsgSigTooLong(),
//messages.SignedMsgNoSigners(),
//messages.SignedMsgDuplicateSigners(),
//messages.SignedMsgMultiSigners(),
Expand Down Expand Up @@ -187,9 +183,8 @@ var AllTests = []SpecTest{
//proposal.PreparedPreviouslyJustification(),
//proposal.DifferentJustifications(),
//proposal.JustificationsNotHeighest(),
//proposal.JustificationsValueNotJustified(),
//proposal.DuplicateMsg(),
//proposal.DuplicateMsgDifferentValue(),
//proposal.DuplicateMsgDifferentRoot(),
//proposal.FirstRoundJustification(),
//proposal.FutureRoundPrevNotPrepared(),
//proposal.FutureRound(),
Expand Down Expand Up @@ -217,7 +212,6 @@ var AllTests = []SpecTest{
//
//prepare.DuplicateMsg(),
//prepare.HappyFlow(),
//prepare.InvalidPrepareData(),
//prepare.MultiSigner(),
//prepare.NoPreviousProposal(),
//prepare.OldRound(),
Expand All @@ -233,7 +227,6 @@ var AllTests = []SpecTest{
//commit.PastRound(),
//commit.DuplicateMsg(),
//commit.HappyFlow(),
//commit.InvalidCommitData(),
//commit.PostDecided(),
//commit.WrongData1(),
//commit.WrongData2(),
Expand Down Expand Up @@ -262,9 +255,7 @@ var AllTests = []SpecTest{
//roundchange.JustificationMultiSigners(),
//roundchange.JustificationInvalidSig(),
//roundchange.JustificationInvalidRound(),
//roundchange.JustificationInvalidPrepareData(),
//roundchange.JustificationDuplicateMsg(),
//roundchange.InvalidRoundChangeData(),
//roundchange.F1DifferentFutureRounds(),
//roundchange.F1DifferentFutureRoundsNotPrepared(),
//roundchange.PastRound(),
Expand Down
27 changes: 0 additions & 27 deletions qbft/spectest/tests/commit/invalid_commit_data.go

This file was deleted.

2 changes: 1 addition & 1 deletion qbft/spectest/tests/controller/decided/current_instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func CurrentInstance() *tests.ControllerSpecTest {
DecidedCnt: 1,
DecidedVal: testingutils.TestingQBFTFullData,
},
ControllerPostRoot: "12fb900494537e891f774dacdfc1ea1ae9e11fdb099221eed157b0b517672cae",
ControllerPostRoot: "9a5519c1584d326e7c20cb1a824af5dc7139bac2f4d1ced2ff13b5aacfe9ab33",
},
},
}
Expand Down
14 changes: 11 additions & 3 deletions qbft/spectest/tests/controller/decided/invalid_val_check.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package decided

import (
"crypto/sha256"
"github.com/bloxapp/ssv-spec/qbft"
"github.com/bloxapp/ssv-spec/qbft/spectest/tests"
"github.com/bloxapp/ssv-spec/types"
Expand All @@ -17,14 +18,21 @@ func InvalidValCheckData() *tests.ControllerSpecTest {
{
InputValue: []byte{1, 2, 3, 4},
InputMessages: []*qbft.SignedMessage{
// how to pass invalid value?
testingutils.TestingCommitMultiSignerMessage([]*bls.SecretKey{ks.Shares[1], ks.Shares[2], ks.Shares[3]}, []types.OperatorID{1, 2, 3}),
testingutils.TestingCommitMultiSignerMessageWithParams(
[]*bls.SecretKey{ks.Shares[1], ks.Shares[2], ks.Shares[3]},
[]types.OperatorID{1, 2, 3},
qbft.FirstRound,
qbft.FirstHeight,
testingutils.TestingIdentifier,
sha256.Sum256(testingutils.TestingInvalidValueCheck),
testingutils.TestingInvalidValueCheck,
),
},
ExpectedDecidedState: tests.DecidedState{
DecidedCnt: 1,
DecidedVal: testingutils.TestingInvalidValueCheck,
},
ControllerPostRoot: "befc8626cb71ca1b8493d41f54a709b22bbf530302177b8668fd77562ca3040e",
ControllerPostRoot: "c7420429b97ed92ad8f21bdef11421c74d86c5d93131a8942d825d1c0aab969c",
},
},
}
Expand Down
2 changes: 1 addition & 1 deletion qbft/spectest/tests/controller/decided/late_decided.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
func LateDecided() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()
msgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, qbft.FirstHeight, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, qbft.FirstHeight, ks)
msgs = append(msgs, testingutils.TestingCommitMultiSignerMessage([]*bls.SecretKey{ks.Shares[1], ks.Shares[2], ks.Shares[4]}, []types.OperatorID{1, 2, 4}))
return &tests.ControllerSpecTest{
Name: "decide late decided",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
func LateDecidedBiggerQuorum() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()
msgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, qbft.FirstHeight, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, qbft.FirstHeight, ks)
msgs = append(msgs, testingutils.TestingCommitMultiSignerMessage([]*bls.SecretKey{ks.Shares[1], ks.Shares[2], ks.Shares[3], ks.Shares[4]}, []types.OperatorID{1, 2, 3, 4}))
return &tests.ControllerSpecTest{
Name: "decide late decided bigger quorum",
Expand Down
2 changes: 1 addition & 1 deletion qbft/spectest/tests/controller/futuremsg/no_signers.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ func NoSigners() *ControllerSyncSpecTest {
ks := testingutils.Testing4SharesSet()

msg := testingutils.TestingPrepareMessageWithParams(
ks.Shares[3], 3, 3, 10, testingutils.DefaultIdentifier, testingutils.TestingQBFTRootData)
ks.Shares[3], 3, 3, 10, testingutils.TestingIdentifier, testingutils.TestingQBFTRootData)
msg.Signers = []types.OperatorID{}

return &ControllerSyncSpecTest{
Expand Down
2 changes: 1 addition & 1 deletion qbft/spectest/tests/controller/futuremsg/unknown_signer.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ func UnknownSigner() *ControllerSyncSpecTest {
ks := testingutils.Testing4SharesSet()

msg := testingutils.TestingPrepareMessageWithParams(ks.Shares[3], 3, 3, 10,
testingutils.DefaultIdentifier, testingutils.TestingQBFTRootData)
testingutils.TestingIdentifier, testingutils.TestingQBFTRootData)
msg.Signers = []types.OperatorID{10}

return &ControllerSyncSpecTest{
Expand Down
2 changes: 1 addition & 1 deletion qbft/spectest/tests/controller/futuremsg/wrong_sig.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func WrongSig() *ControllerSyncSpecTest {
Name: "future msg wrong sig",
InputMessages: []*qbft.SignedMessage{
testingutils.TestingPrepareMessageWithParams(ks.Shares[3], 2, 3, 10,
testingutils.DefaultIdentifier, testingutils.TestingQBFTRootData),
testingutils.TestingIdentifier, testingutils.TestingQBFTRootData),
},
SyncDecidedCalledCnt: 0,
ControllerPostRoot: "6bd17213f8e308190c4ebe49a22ec00c91ffd4c91a5515583391e9977423370f",
Expand Down
2 changes: 1 addition & 1 deletion qbft/spectest/tests/controller/latemsg/late_commit.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func LateCommit() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()

msgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, qbft.FirstHeight, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, qbft.FirstHeight, ks)
msgs = append(msgs, testingutils.TestingCommitMessage(ks.Shares[4], types.OperatorID(4)))

return &tests.ControllerSpecTest{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func LateCommitPastInstance() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()

allMsgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, 5, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, 5, ks)

msgPerHeight := make(map[qbft.Height][]*qbft.SignedMessage)
msgPerHeight[qbft.FirstHeight] = allMsgs[0:7]
Expand Down
2 changes: 1 addition & 1 deletion qbft/spectest/tests/controller/latemsg/late_prepare.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func LatePrepare() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()

msgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, qbft.FirstHeight, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, qbft.FirstHeight, ks)
msgs = append(msgs, testingutils.TestingPrepareMessage(ks.Shares[4], 4))

return &tests.ControllerSpecTest{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func LatePreparePastInstance() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()

allMsgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, 5, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, 5, ks)

msgPerHeight := make(map[qbft.Height][]*qbft.SignedMessage)
msgPerHeight[qbft.FirstHeight] = allMsgs[0:7]
Expand Down
2 changes: 1 addition & 1 deletion qbft/spectest/tests/controller/latemsg/late_proposal.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func LateProposal() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()

msgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, qbft.FirstHeight, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, qbft.FirstHeight, ks)
msgs = append(msgs, testingutils.TestingProposalMessage(ks.Shares[1], 1))

return &tests.ControllerSpecTest{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func LateProposalPastInstance() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()

allMsgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, 5, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, 5, ks)

msgPerHeight := make(map[qbft.Height][]*qbft.SignedMessage)
msgPerHeight[qbft.FirstHeight] = allMsgs[0:7]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func LateRoundChange() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()

msgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, qbft.FirstHeight, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, qbft.FirstHeight, ks)
msgs = append(msgs, testingutils.TestingRoundChangeMessage(ks.Shares[4], 4))

return &tests.ControllerSpecTest{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func LateRoundChangePastInstance() *tests.ControllerSpecTest {
ks := testingutils.Testing4SharesSet()

allMsgs := testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, 5, ks)
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, 5, ks)

msgPerHeight := make(map[qbft.Height][]*qbft.SignedMessage)
msgPerHeight[qbft.FirstHeight] = allMsgs[0:7]
Expand Down
2 changes: 1 addition & 1 deletion qbft/spectest/tests/controller/processmsg/full_decided.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ func FullDecided() *tests.ControllerSpecTest {
{
InputValue: testingutils.TestingQBFTFullData,
InputMessages: testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, qbft.FirstHeight, ks),
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, qbft.FirstHeight, ks),
ExpectedDecidedState: tests.DecidedState{
DecidedVal: testingutils.TestingQBFTFullData,
DecidedCnt: 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ func BroadcastedDecided() *tests.ControllerSpecTest {
{
InputValue: []byte{1, 2, 3, 4},
InputMessages: testingutils.DecidingMsgsForHeightWithRoot(testingutils.TestingQBFTRootData,
testingutils.TestingQBFTFullData, testingutils.DefaultIdentifier, qbft.FirstHeight, ks),
testingutils.TestingQBFTFullData, testingutils.TestingIdentifier, qbft.FirstHeight, ks),
ExpectedDecidedState: tests.DecidedState{
DecidedVal: testingutils.TestingQBFTFullData,
DecidedCnt: 1,
Expand Down
24 changes: 0 additions & 24 deletions qbft/spectest/tests/messages/rc_invalid_justifications.go

This file was deleted.

23 changes: 0 additions & 23 deletions qbft/spectest/tests/messages/rc_invalid_prepared_round.go

This file was deleted.

24 changes: 0 additions & 24 deletions qbft/spectest/tests/messages/signature_too_long.go

This file was deleted.

24 changes: 0 additions & 24 deletions qbft/spectest/tests/messages/signature_too_short.go

This file was deleted.

5 changes: 0 additions & 5 deletions qbft/spectest/tests/messages_spectest.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package tests

import (
"errors"
"github.com/bloxapp/ssv-spec/qbft"
"github.com/stretchr/testify/require"
"testing"
Expand All @@ -25,10 +24,6 @@ func (test *MsgSpecTest) Run(t *testing.T) {
continue
}

if msg.Message.MsgType == qbft.RoundChangeMsgType && len(msg.Message.RoundChangeJustification) == 0 {
lastErr = errors.New("round change justification invalid")
}

if len(test.EncodedMessages) > 0 {
byts, err := msg.Encode()
require.NoError(t, err)
Expand Down
Loading