Skip to content

Commit 7612f13

Browse files
committed
Fix test that checks extended-redis-compatibility config deprecation rules (#2629)
Following the decision in #2189, we need to fix this test because the `extended-redis-compatibility` config option is not going to be deprecated in 9.0. This commit changes the test to postpone the deprecation of `extended-redis-compatibility` until 10.0 release. Signed-off-by: Ricardo Dias <[email protected]>
1 parent 69b397f commit 7612f13

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

tests/unit/other.tcl

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -364,19 +364,19 @@ start_server {tags {"other"}} {
364364
# effect in 9.x and be deleted in 10.0.
365365
set hello [r hello 3]
366366
set version [dict get $hello version]
367-
if {[string match "10.*" $version]} {
367+
if {[string match "11.*" $version]} {
368368
# Check that the config doesn't exist anymore.
369369
assert_error "ERR Unknown*" {r config set extended-redis-compatibility yes}
370370
error "We shall also delete this test case"
371-
} elseif {[string match "9.*" $version]} {
372-
# This config is scheduled for removal. In 9.x it should still
371+
} elseif {[string match "10.*" $version]} {
372+
# This config is scheduled for removal. In 10.x it should still
373373
# exists but have no effect.
374374
r config set extended-redis-compatibility yes
375375
set hello [r hello 3]
376376
assert_equal valkey [dict get $hello server]
377377
assert_equal $version [dict get $hello version]
378378
r config set extended-redis-compatibility no
379-
} elseif {[string match "8.*" $version] || ($version eq "255.255.255")} {
379+
} elseif {[string match "8.*" $version] || [string match "9.*" $version] || ($version eq "255.255.255")} {
380380
# In 8.x, the config shall work and affect HELLO server and version.
381381
r config set extended-redis-compatibility yes
382382
set hello [r hello 3]
@@ -467,7 +467,7 @@ start_server {tags {"other external:skip"}} {
467467

468468
assert_equal "TEST" [lindex $cmdline 0]
469469
assert_match "*/valkey-server" [lindex $cmdline 1]
470-
470+
471471
if {$::tls} {
472472
set expect_port [srv 0 pport]
473473
set expect_tls_port [srv 0 port]
@@ -555,7 +555,7 @@ start_cluster 1 0 {tags {"other external:skip cluster slow"}} {
555555
test "CLUSTER FORGET with invalid node ID" {
556556
catch {r cluster forget 1} err
557557
set _ $err
558-
} {*ERR Unknown node*}
558+
} {*ERR Unknown node*}
559559
}
560560

561561
start_server {tags {"other external:skip"}} {
@@ -575,7 +575,7 @@ start_server {tags {"other external:skip"}} {
575575
[dict get [r memory stats] db.$dbnum overhead.hashtable.main] < 400
576576
} else {
577577
fail "dict did not resize in time"
578-
}
578+
}
579579
}
580580
}
581581

0 commit comments

Comments
 (0)