From 7a30be123794ffb339a3a73e094d255a065b6a60 Mon Sep 17 00:00:00 2001 From: antirez Date: Tue, 31 Jul 2018 17:28:30 +0200 Subject: Minor improvements to PR #5187. --- tests/integration/psync2.tcl | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'tests/integration/psync2.tcl') diff --git a/tests/integration/psync2.tcl b/tests/integration/psync2.tcl index 3d9e5527a..b76f36363 100644 --- a/tests/integration/psync2.tcl +++ b/tests/integration/psync2.tcl @@ -33,9 +33,8 @@ start_server {} { set cycle 1 while {([clock seconds]-$start_time) < $duration} { - test "PSYNC2: --- CYCLE $cycle ---" { - incr cycle - } + test "PSYNC2: --- CYCLE $cycle ---" {} + incr cycle # Create a random replication layout. # Start with switching master (this simulates a failover). @@ -139,6 +138,11 @@ start_server {} { } assert {$sum == 4} } + + # Limit anyway the maximum number of cycles. This is useful when the + # test is skipped via --only option of the test suite. In that case + # we don't want to see many seconds of this test being just skipped. + if {$cycle > 50} break } test "PSYNC2: Bring the master back again for next test" { -- cgit v1.2.1