diff --git a/config/toml.go b/config/toml.go index 882d2289a..23a6fecde 100644 --- a/config/toml.go +++ b/config/toml.go @@ -287,7 +287,7 @@ var testGenesis = `{ }` var testPrivValidator = `{ - "address": "D028C9981F7A87F3093672BF0D5B0E2A1B3ED456", + "address": "515252BC8788931ADFF4796A389C9B1F7925A1B7", "pub_key": { "type": "AC26791624DE60", "value": "AT/+aaL1eB0477Mud9JMm8Sh8BIvOYlPGC9KkIUmFaE=" diff --git a/consensus/state.go b/consensus/state.go index a64ef3e49..42de5fec8 100644 --- a/consensus/state.go +++ b/consensus/state.go @@ -4,14 +4,15 @@ import ( "bytes" "errors" "fmt" - fail "github.com/ebuchman/fail-test" - cmn "github.com/tendermint/tmlibs/common" - "github.com/tendermint/tmlibs/log" "reflect" "runtime/debug" "sync" "time" + fail "github.com/ebuchman/fail-test" + cmn "github.com/tendermint/tmlibs/common" + "github.com/tendermint/tmlibs/log" + cfg "github.com/tendermint/tendermint/config" cstypes "github.com/tendermint/tendermint/consensus/types" "github.com/tendermint/tendermint/p2p" diff --git a/consensus/state_test.go b/consensus/state_test.go index fea6cf6ae..6efc21205 100644 --- a/consensus/state_test.go +++ b/consensus/state_test.go @@ -409,8 +409,7 @@ func TestStateLockNoPOL(t *testing.T) { validatePrevote(t, cs1, 1, vss[0], rs.LockedBlock.Hash()) // add a conflicting prevote from the other validator - fmt.Println(">>", rs.ProposalBlock) - signAddVotes(cs1, types.VoteTypePrevote, hash, rs.ProposalBlock.MakePartSet(partSize).Header(), vs2) + signAddVotes(cs1, types.VoteTypePrevote, hash, rs.LockedBlock.MakePartSet(partSize).Header(), vs2) <-voteCh // now we're going to enter prevote again, but with invalid args @@ -425,7 +424,7 @@ func TestStateLockNoPOL(t *testing.T) { // add conflicting precommit from vs2 // NOTE: in practice we should never get to a point where there are precommits for different blocks at the same round - signAddVotes(cs1, types.VoteTypePrecommit, hash, rs.ProposalBlock.MakePartSet(partSize).Header(), vs2) + signAddVotes(cs1, types.VoteTypePrecommit, hash, rs.LockedBlock.MakePartSet(partSize).Header(), vs2) <-voteCh // (note we're entering precommit for a second time this round, but with invalid args diff --git a/consensus/wal.go b/consensus/wal.go index a615720be..bc9afff64 100644 --- a/consensus/wal.go +++ b/consensus/wal.go @@ -113,7 +113,6 @@ func (wal *baseWAL) OnStop() { // called in newStep and for each pass in receiveRoutine func (wal *baseWAL) Save(msg WALMessage) { - fmt.Println("!!", 1) if wal == nil { return } diff --git a/consensus/wal_test.go b/consensus/wal_test.go index 8c95748eb..9925b691b 100644 --- a/consensus/wal_test.go +++ b/consensus/wal_test.go @@ -35,7 +35,7 @@ func TestWALEncoderDecoder(t *testing.T) { decoded, err := dec.Decode() require.NoError(t, err) - assert.Equal(t, msg.Time.Truncate(time.Millisecond), decoded.Time) + assert.True(t, msg.Time.Equal(decoded.Time)) assert.Equal(t, msg.Msg, decoded.Msg) } }