mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-23 00:28:26 -05:00
Properly wait the slave to sync with master in BRPOPLPUSH test.
This commit is contained in:
parent
2d4b55214f
commit
d9241b35e5
@ -2,9 +2,13 @@ start_server {tags {"repl"}} {
|
|||||||
start_server {} {
|
start_server {} {
|
||||||
test {First server should have role slave after SLAVEOF} {
|
test {First server should have role slave after SLAVEOF} {
|
||||||
r -1 slaveof [srv 0 host] [srv 0 port]
|
r -1 slaveof [srv 0 host] [srv 0 port]
|
||||||
after 1000
|
wait_for_condition 50 100 {
|
||||||
s -1 role
|
[s -1 role] eq {slave} &&
|
||||||
} {slave}
|
[string match {*master_link_status:up*} [r -1 info replication]]
|
||||||
|
} else {
|
||||||
|
fail "Can't turn the instance into a slave"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
test {BRPOPLPUSH replication, when blocking against empty list} {
|
test {BRPOPLPUSH replication, when blocking against empty list} {
|
||||||
set rd [redis_deferring_client]
|
set rd [redis_deferring_client]
|
||||||
|
Loading…
Reference in New Issue
Block a user