diff options
Diffstat (limited to 'tests/integration')
-rw-r--r-- | tests/integration/psync2-master-restart.tcl | 3 | ||||
-rw-r--r-- | tests/integration/psync2.tcl | 2 | ||||
-rw-r--r-- | tests/integration/rdb.tcl | 5 |
3 files changed, 9 insertions, 1 deletions
diff --git a/tests/integration/psync2-master-restart.tcl b/tests/integration/psync2-master-restart.tcl index 03470bf81..e925aaab8 100644 --- a/tests/integration/psync2-master-restart.tcl +++ b/tests/integration/psync2-master-restart.tcl @@ -11,6 +11,9 @@ start_server {} { set sub_replica [srv -2 client] + # Make sure the server saves an RDB on shutdown + $master config set save "3600 1" + # Because we will test partial resync later, we don’t want a timeout to cause # the master-replica disconnect, then the extra reconnections will break the # sync_partial_ok stat test diff --git a/tests/integration/psync2.tcl b/tests/integration/psync2.tcl index a258f1b83..4abe059b1 100644 --- a/tests/integration/psync2.tcl +++ b/tests/integration/psync2.tcl @@ -355,6 +355,8 @@ start_server {} { set sync_partial [status $R($master_id) sync_partial_ok] set sync_partial_err [status $R($master_id) sync_partial_err] catch { + # Make sure the server saves an RDB on shutdown + $R($slave_id) config set save "900 1" $R($slave_id) config rewrite restart_server [expr {0-$slave_id}] true false set R($slave_id) [srv [expr {0-$slave_id}] client] diff --git a/tests/integration/rdb.tcl b/tests/integration/rdb.tcl index 2362ef079..cce21671f 100644 --- a/tests/integration/rdb.tcl +++ b/tests/integration/rdb.tcl @@ -173,7 +173,7 @@ start_server {} { } test {client freed during loading} { - start_server [list overrides [list key-load-delay 50 loading-process-events-interval-bytes 1024 rdbcompression no]] { + start_server [list overrides [list key-load-delay 50 loading-process-events-interval-bytes 1024 rdbcompression no save "900 1"]] { # create a big rdb that will take long to load. it is important # for keys to be big since the server processes events only once in 2mb. # 100mb of rdb, 100k keys will load in more than 5 seconds @@ -370,6 +370,9 @@ start_server [list overrides [list "dir" $server_path "dbfilename" "scriptbackup start_server {} { test "failed bgsave prevents writes" { + # Make sure the server saves an RDB on shutdown + r config set save "900 1" + r config set rdb-key-save-delay 10000000 populate 1000 r set x x |