From 278c4625dbb3c583be5c611f90f27de7244bd806 Mon Sep 17 00:00:00 2001 From: Marko Baricevic Date: Wed, 10 Jul 2019 13:25:21 +0200 Subject: [PATCH] further changes --- state/txindex/indexer_service_test.go | 2 ++ tools/tm-bench/statistics.go | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/state/txindex/indexer_service_test.go b/state/txindex/indexer_service_test.go index fcd97a09..1ecc2294 100644 --- a/state/txindex/indexer_service_test.go +++ b/state/txindex/indexer_service_test.go @@ -8,6 +8,7 @@ import ( "github.com/stretchr/testify/require" abci "github.com/tendermint/tendermint/abci/types" + cmn "github.com/tendermint/tendermint/libs/common" "github.com/tendermint/tendermint/libs/db" "github.com/tendermint/tendermint/libs/log" "github.com/tendermint/tendermint/state/txindex" @@ -37,6 +38,7 @@ func TestIndexerServiceIndexesBlocks(t *testing.T) { eventBus.PublishEventNewBlock(types.EventDataNewBlock{ Block: &types.Block{ Header: types.Header{Height: 1}, + Data: types.Data{Txs: types.Txs{cmn.RandBytes(123), cmn.RandBytes(124)}}, }, }) txResult1 := &types.TxResult{ diff --git a/tools/tm-bench/statistics.go b/tools/tm-bench/statistics.go index 43e0bda7..c1110a83 100644 --- a/tools/tm-bench/statistics.go +++ b/tools/tm-bench/statistics.go @@ -66,8 +66,8 @@ func calculateStatistics( // increase number of blocks for that second numBlocksPerSec[sec]++ - // TODO: add tracking for tx/sec // increase number of txs for that second + // TODO: add tracking for tx/sec numTxsPerSec[sec] += 1 logger.Debug(fmt.Sprintf("%d txs at block height %d", 1, blockMeta.Header.Height)) }