File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -111,7 +111,27 @@ func TestAssertValidForNextState(t *testing.T) {
111111 data : & Data {},
112112 expectedError : "dataHash from the header does not match with hash" ,
113113 },
114- "last header hash mismatch" : {
114+ "last header hash mismatch (first time)" : {
115+ state : State {
116+ ChainID : "test-chain" ,
117+ LastHeaderHash : []byte ("hash" ),
118+ LastBlockHeight : 1 ,
119+ LastBlockTime : now ,
120+ },
121+ header : & SignedHeader {
122+ Header : Header {
123+ BaseHeader : BaseHeader {
124+ ChainID : "test-chain" , Height : 2 ,
125+ Time : nowUnixNano ,
126+ },
127+ DataHash : dataHashForEmptyTxs ,
128+ LastHeaderHash : []byte ("other-hash" ),
129+ },
130+ },
131+ data : & Data {},
132+ expectedError : "" ,
133+ },
134+ "last header hash mismatch (second time)" : {
115135 state : State {
116136 ChainID : "test-chain" ,
117137 LastHeaderHash : []byte ("hash" ),
You can’t perform that action at this time.
0 commit comments