From b1b784cfa837cfbcd14f3bb38d97c2a899ff882a Mon Sep 17 00:00:00 2001 From: Ethan Buchman Date: Thu, 31 May 2018 10:48:20 -0400 Subject: [PATCH] fix tests --- example/kvstore/helpers.go | 4 ++-- tests/server/client.go | 4 ++-- types/params.go | 8 ++++---- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/example/kvstore/helpers.go b/example/kvstore/helpers.go index e302a6d..196aab3 100644 --- a/example/kvstore/helpers.go +++ b/example/kvstore/helpers.go @@ -33,7 +33,7 @@ func RandVals(cnt int) []types.Validator { // don't make any tx that modify the validator state func InitKVStore(app *PersistentKVStoreApplication) { app.InitChain(types.ParamsInitChain{ - Validators: RandVals(1), - GenesisBytes: []byte("[]"), + Validators: RandVals(1), + GenesisFile: types.GenesisFile{}, }) } diff --git a/tests/server/client.go b/tests/server/client.go index e1d0285..bc2d6bd 100644 --- a/tests/server/client.go +++ b/tests/server/client.go @@ -20,8 +20,8 @@ func InitChain(client abcicli.Client) error { vals[i] = &v } _, err := client.InitChainSync(types.RequestInitChain{ - Validators: vals, - GenesisBytes: []byte("{}"), + Validators: vals, + GenesisFile: &types.GenesisFile{}, }) if err != nil { fmt.Printf("Failed test: InitChain - %v\n", err) diff --git a/types/params.go b/types/params.go index dbf5021..893cead 100644 --- a/types/params.go +++ b/types/params.go @@ -30,8 +30,8 @@ func ToParamsSetOption(req RequestSetOption) ParamsSetOption { } type ParamsInitChain struct { - Validators []Validator `json:"validators"` - GenesisBytes []byte `json:"genesis_bytes,omitempty"` + Validators []Validator `json:"validators"` + GenesisFile GenesisFile `json:"genesis_bytes,omitempty"` } func ToParamsInitChain(req RequestInitChain) ParamsInitChain { @@ -41,8 +41,8 @@ func ToParamsInitChain(req RequestInitChain) ParamsInitChain { vals[i] = *v } return ParamsInitChain{ - Validators: vals, - GenesisBytes: req.GenesisBytes, + Validators: vals, + GenesisFile: *req.GenesisFile, } }