Fix replica count check in migration tests. (#10140)

Tests were not using loop index as node id, checking replica count of the same node over and over.
This commit is contained in:
Ozan Tezcan 2022-01-19 12:36:24 +03:00 committed by GitHub
parent 1af0a2c5ae
commit 72e1b5de4d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View File

@ -18,7 +18,7 @@ test "Each master should have two replicas attached" {
foreach_redis_id id {
if {$id < 5} {
wait_for_condition 1000 50 {
[llength [lindex [R 0 role] 2]] == 2
[llength [lindex [R $id role] 2]] == 2
} else {
fail "Master #$id does not have 2 slaves as expected"
}

View File

@ -21,7 +21,7 @@ test "Each master should have at least two replicas attached" {
foreach_redis_id id {
if {$id < 5} {
wait_for_condition 1000 50 {
[llength [lindex [R 0 role] 2]] >= 2
[llength [lindex [R $id role] 2]] >= 2
} else {
fail "Master #$id does not have 2 slaves as expected"
}

View File

@ -19,7 +19,7 @@ test "Each master should have at least two replicas attached" {
foreach_redis_id id {
if {$id < 5} {
wait_for_condition 1000 50 {
[llength [lindex [R 0 role] 2]] >= 2
[llength [lindex [R $id role] 2]] >= 2
} else {
fail "Master #$id does not have 2 slaves as expected"
}
@ -61,7 +61,7 @@ test "Each master should have at least two replicas attached" {
foreach_redis_id id {
if {$id < 5} {
wait_for_condition 1000 50 {
[llength [lindex [R 0 role] 2]] >= 2
[llength [lindex [R $id role] 2]] >= 2
} else {
fail "Master #$id does not have 2 slaves as expected"
}