From 678599c7d4efc36978d5a075488ba52da9205310 Mon Sep 17 00:00:00 2001 From: Ethan Buchman Date: Tue, 23 Aug 2016 11:33:18 -0400 Subject: [PATCH] consensus: add note about replay test --- consensus/replay_test.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/consensus/replay_test.go b/consensus/replay_test.go index a9376d0e4..654cec9c2 100644 --- a/consensus/replay_test.go +++ b/consensus/replay_test.go @@ -101,7 +101,10 @@ func waitForBlock(newBlockCh chan interface{}) { func runReplayTest(t *testing.T, cs *ConsensusState, fileName string, newBlockCh chan interface{}) { cs.config.Set("cswal", fileName) cs.Start() - // wait to make a new block + // Wait to make a new block. + // This is just a signal that we haven't halted; its not something contained in the WAL itself. + // Assuming the consensus state is running, replay of any WAL, including the empty one, + // should eventually be followed by a new block, or else something is wrong waitForBlock(newBlockCh) cs.Stop() }