EndBlock also returns ResponseEndBlock

This commit is contained in:
Jae Kwon
2017-01-12 14:50:41 -05:00
committed by Ethan Buchman
parent 8b76f3dd00
commit f8167872d8
13 changed files with 46 additions and 32 deletions
+2 -2
View File
@@ -179,10 +179,10 @@ func makeApplyBlock(t *testing.T, dummy types.Application, heightInt int, diff [
t.Fatal(r)
}
}
diff2 := dummyChain.EndBlock(height)
resEndBlock := dummyChain.EndBlock(height)
dummy.Commit()
valsEqual(t, diff, diff2)
valsEqual(t, diff, resEndBlock.Diffs)
}
+2 -2
View File
@@ -113,8 +113,8 @@ func (app *PersistentDummyApplication) BeginBlock(hash []byte, header *types.Hea
}
// Update the validator set
func (app *PersistentDummyApplication) EndBlock(height uint64) (diffs []*types.Validator) {
return app.changes
func (app *PersistentDummyApplication) EndBlock(height uint64) (resEndBlock types.ResponseEndBlock) {
return types.ResponseEndBlock{Diffs: app.changes}
}
//-----------------------------------------