Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
46a51cdc
Unverified
Commit
46a51cdc
authored
Nov 28, 2018
by
Salvatore Sanfilippo
Committed by
GitHub
Nov 28, 2018
Browse files
Merge pull request #5549 from oranagra/fix_test_races
fix small test suite race conditions
parents
4c544394
d0850369
Changes
3
Hide whitespace changes
Inline
Side-by-side
tests/support/util.tcl
View file @
46a51cdc
...
...
@@ -91,6 +91,14 @@ proc wait_for_sync r {
}
}
proc wait_for_ofs_sync
{
r1 r2
}
{
wait_for_condition 50 100
{
[
status $r1 master_repl_offset
]
eq
[
status $r2 master_repl_offset
]
}
else
{
fail
"replica didn't sync in time"
}
}
# Random integer between 0 and max
(
excluded
)
.
proc randomInt
{
max
}
{
expr
{
int
(
rand
()
*$max
)}
...
...
tests/unit/memefficiency.tcl
View file @
46a51cdc
...
...
@@ -90,6 +90,7 @@ start_server {tags {"defrag"}} {
test
"Active defrag big keys"
{
r flushdb
r config resetstat
r config set save
""
;
# prevent bgsave from interfereing with save below
r config set activedefrag no
r config set active-defrag-max-scan-fields 1000
r config set active-defrag-threshold-lower 5
...
...
tests/unit/type/stream-cgroups.tcl
View file @
46a51cdc
...
...
@@ -231,6 +231,8 @@ start_server {
}
}
wait_for_ofs_sync $master $slave
# Turn slave into master
$slave slaveof no one
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment