mirror of
https://github.com/fluencelabs/tendermint
synced 2025-06-12 04:41:22 +00:00
new logging
This commit is contained in:
@ -12,9 +12,9 @@ import (
|
||||
"github.com/stretchr/testify/require"
|
||||
crypto "github.com/tendermint/go-crypto"
|
||||
wire "github.com/tendermint/go-wire"
|
||||
cmn "github.com/tendermint/tmlibs/common"
|
||||
|
||||
cfg "github.com/tendermint/tendermint/config"
|
||||
"github.com/tendermint/tmlibs/log"
|
||||
)
|
||||
|
||||
var (
|
||||
@ -50,7 +50,8 @@ func NewTestReactor(channels []*ChannelDescriptor, logMessages bool) *TestReacto
|
||||
logMessages: logMessages,
|
||||
msgsReceived: make(map[byte][]PeerMessage),
|
||||
}
|
||||
tr.BaseReactor = *NewBaseReactor(log, "TestReactor", tr)
|
||||
tr.BaseReactor = *NewBaseReactor("TestReactor", tr)
|
||||
tr.SetLogger(log.TestingLogger())
|
||||
return tr
|
||||
}
|
||||
|
||||
@ -285,7 +286,6 @@ func TestSwitchReconnectsToPersistentPeer(t *testing.T) {
|
||||
}
|
||||
|
||||
func BenchmarkSwitches(b *testing.B) {
|
||||
|
||||
b.StopTimer()
|
||||
|
||||
s1, s2 := makeSwitchPair(b, func(i int, sw *Switch) *Switch {
|
||||
@ -322,10 +322,9 @@ func BenchmarkSwitches(b *testing.B) {
|
||||
}
|
||||
}
|
||||
|
||||
log.Warn(cmn.Fmt("success: %v, failure: %v", numSuccess, numFailure))
|
||||
b.Logf("success: %v, failure: %v", numSuccess, numFailure)
|
||||
|
||||
// Allow everything to flush before stopping switches & closing connections.
|
||||
b.StopTimer()
|
||||
time.Sleep(1000 * time.Millisecond)
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user