Skip to content

Commit

Permalink
Fix timing issue in cluster-shards tests (#1243)
Browse files Browse the repository at this point in the history
The cluster-node-timeout is 3000 in our tests, the timing test wasn't
succeeding, so extending the wait_for made them much more reliable.

Signed-off-by: Binbin <[email protected]>
  • Loading branch information
enjoy-binbin authored Nov 2, 2024
1 parent 0d7b234 commit a102852
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tests/cluster/tests/28-cluster-shards.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ test "Kill a node and tell the replica to immediately takeover" {

# Primary 0 node should report as fail, wait until the new primary acknowledges it.
test "Verify health as fail for killed node" {
wait_for_condition 50 100 {
wait_for_condition 1000 50 {
"fail" eq [dict get [get_node_info_from_shard $node_0_id 4 "node"] "health"]
} else {
fail "New primary never detected the node failed"
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/cluster/cluster-shards.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ start_cluster 3 3 {tags {external:skip cluster}} {
}

test "Verify health as fail for killed node" {
wait_for_condition 50 100 {
wait_for_condition 1000 50 {
"fail" eq [dict get [get_node_info_from_shard $node_0_id $validation_node "node"] "health"]
} else {
fail "New primary never detected the node failed"
Expand Down

0 comments on commit a102852

Please sign in to comment.