summaryrefslogtreecommitdiff
path: root/tests/cluster
diff options
context:
space:
mode:
authorBinbin <binloveplay1314@qq.com>2021-06-10 20:39:33 +0800
committerGitHub <noreply@github.com>2021-06-10 15:39:33 +0300
commit0bfccc55e2df349104b34608365dc17db8e0a749 (patch)
tree1861554f79d98e4c5352d879b2e08979e69ba2f1 /tests/cluster
parent8a86bca5ed09094b561284fcb5b1fc416a4016dc (diff)
downloadredis-0bfccc55e2df349104b34608365dc17db8e0a749.tar.gz
Fixed some typos, add a spell check ci and others minor fix (#8890)
This PR adds a spell checker CI action that will fail future PRs if they introduce typos and spelling mistakes. This spell checker is based on blacklist of common spelling mistakes, so it will not catch everything, but at least it is also unlikely to cause false positives. Besides that, the PR also fixes many spelling mistakes and types, not all are a result of the spell checker we use. Here's a summary of other changes: 1. Scanned the entire source code and fixes all sorts of typos and spelling mistakes (including missing or extra spaces). 2. Outdated function / variable / argument names in comments 3. Fix outdated keyspace masks error log when we check `config.notify-keyspace-events` in loadServerConfigFromString. 4. Trim the white space at the end of line in `module.c`. Check: https://github.com/redis/redis/pull/7751 5. Some outdated https link URLs. 6. Fix some outdated comment. Such as: - In README: about the rdb, we used to said create a `thread`, change to `process` - dbRandomKey function coment (about the dictGetRandomKey, change to dictGetFairRandomKey) - notifyKeyspaceEvent fucntion comment (add type arg) - Some others minor fix in comment (Most of them are incorrectly quoted by variable names) 7. Modified the error log so that users can easily distinguish between TCP and TLS in `changeBindAddr`
Diffstat (limited to 'tests/cluster')
-rw-r--r--tests/cluster/tests/03-failover-loop.tcl2
-rw-r--r--tests/cluster/tests/08-update-msg.tcl4
-rw-r--r--tests/cluster/tests/12.1-replica-migration-3.tcl2
-rw-r--r--tests/cluster/tests/16-transactions-on-replica.tcl4
-rw-r--r--tests/cluster/tests/18-info.tcl8
5 files changed, 10 insertions, 10 deletions
diff --git a/tests/cluster/tests/03-failover-loop.tcl b/tests/cluster/tests/03-failover-loop.tcl
index 8e1bcd6fe..5c84b2604 100644
--- a/tests/cluster/tests/03-failover-loop.tcl
+++ b/tests/cluster/tests/03-failover-loop.tcl
@@ -1,7 +1,7 @@
# Failover stress test.
# In this test a different node is killed in a loop for N
# iterations. The test checks that certain properties
-# are preseved across iterations.
+# are preserved across iterations.
source "../tests/includes/init-tests.tcl"
diff --git a/tests/cluster/tests/08-update-msg.tcl b/tests/cluster/tests/08-update-msg.tcl
index 6f9661db0..9011f3205 100644
--- a/tests/cluster/tests/08-update-msg.tcl
+++ b/tests/cluster/tests/08-update-msg.tcl
@@ -1,9 +1,9 @@
# Test UPDATE messages sent by other nodes when the currently authorirative
-# master is unavaialble. The test is performed in the following steps:
+# master is unavailable. The test is performed in the following steps:
#
# 1) Master goes down.
# 2) Slave failover and becomes new master.
-# 3) New master is partitoned away.
+# 3) New master is partitioned away.
# 4) Old master returns.
# 5) At this point we expect the old master to turn into a slave ASAP because
# of the UPDATE messages it will receive from the other nodes when its
diff --git a/tests/cluster/tests/12.1-replica-migration-3.tcl b/tests/cluster/tests/12.1-replica-migration-3.tcl
index 46a9f79e3..42620084a 100644
--- a/tests/cluster/tests/12.1-replica-migration-3.tcl
+++ b/tests/cluster/tests/12.1-replica-migration-3.tcl
@@ -53,7 +53,7 @@ test "Wait cluster to be stable" {
}
}
-test "Master #0 stil should have its replicas" {
+test "Master #0 still should have its replicas" {
assert { [llength [lindex [R 0 role] 2]] >= 2 }
}
diff --git a/tests/cluster/tests/16-transactions-on-replica.tcl b/tests/cluster/tests/16-transactions-on-replica.tcl
index baed15fbc..ee9f7c6e6 100644
--- a/tests/cluster/tests/16-transactions-on-replica.tcl
+++ b/tests/cluster/tests/16-transactions-on-replica.tcl
@@ -13,7 +13,7 @@ test "Cluster should start ok" {
set primary [Rn 0]
set replica [Rn 1]
-test "Cant read from replica without READONLY" {
+test "Can't read from replica without READONLY" {
$primary SET a 1
wait_for_ofs_sync $primary $replica
catch {$replica GET a} err
@@ -25,7 +25,7 @@ test "Can read from replica after READONLY" {
assert {[$replica GET a] eq {1}}
}
-test "Can preform HSET primary and HGET from replica" {
+test "Can perform HSET primary and HGET from replica" {
$primary HSET h a 1
$primary HSET h b 2
$primary HSET h c 3
diff --git a/tests/cluster/tests/18-info.tcl b/tests/cluster/tests/18-info.tcl
index 978d9d1da..68c62d357 100644
--- a/tests/cluster/tests/18-info.tcl
+++ b/tests/cluster/tests/18-info.tcl
@@ -13,12 +13,12 @@ test "Cluster should start ok" {
set primary1 [Rn 0]
set primary2 [Rn 1]
-proc cmdstat {instace cmd} {
- return [cmdrstat $cmd $instace]
+proc cmdstat {instance cmd} {
+ return [cmdrstat $cmd $instance]
}
-proc errorstat {instace cmd} {
- return [errorrstat $cmd $instace]
+proc errorstat {instance cmd} {
+ return [errorrstat $cmd $instance]
}
test "errorstats: rejected call due to MOVED Redirection" {