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
0af7fe2c
Unverified
Commit
0af7fe2c
authored
Sep 26, 2021
by
Yossi Gottlieb
Committed by
GitHub
Sep 26, 2021
Browse files
Add --skipfile and --skiptest regex support. (#9555)
Empty patterns are not considered and skipped. Also, improve help text.
parent
7c1f9ef5
Changes
2
Show whitespace changes
Inline
Side-by-side
tests/support/test.tcl
View file @
0af7fe2c
...
@@ -118,7 +118,7 @@ proc wait_for_condition {maxtries delay e _else_ elsescript} {
...
@@ -118,7 +118,7 @@ proc wait_for_condition {maxtries delay e _else_ elsescript} {
proc search_pattern_list
{
value pattern_list
}
{
proc search_pattern_list
{
value pattern_list
}
{
set n 0
set n 0
foreach el $pattern_list
{
foreach el $pattern_list
{
if
{[
regexp -- $el $value
]}
{
if
{
[
string length $el
]
> 0 &&
[
regexp -- $el $value
]}
{
return $n
return $n
}
}
incr n
incr n
...
@@ -128,7 +128,7 @@ proc search_pattern_list {value pattern_list} {
...
@@ -128,7 +128,7 @@ proc search_pattern_list {value pattern_list} {
proc test
{
name code
{
okpattern undefined
}
{
tags
{}}}
{
proc test
{
name code
{
okpattern undefined
}
{
tags
{}}}
{
# abort if test name in skiptests
# abort if test name in skiptests
if
{[
l
search $::skiptests
$name
]
>= 0
}
{
if
{[
search
_pattern_list $name
$::skiptests
]
>= 0
}
{
incr ::num_skipped
incr ::num_skipped
send_data_packet $::test_server_fd skip $name
send_data_packet $::test_server_fd skip $name
return
return
...
...
tests/test_helper.tcl
View file @
0af7fe2c
...
@@ -572,8 +572,8 @@ proc print_help_screen {} {
...
@@ -572,8 +572,8 @@ proc print_help_screen {} {
"--timeout <sec> Test timeout in seconds (default 10 min)."
"--timeout <sec> Test timeout in seconds (default 10 min)."
"--force-failure Force the execution of a test that always fails."
"--force-failure Force the execution of a test that always fails."
"--config <k> <v> Extra config file argument."
"--config <k> <v> Extra config file argument."
"--skipfile <file> Name of a file containing test names that should be skipped (one per line)."
"--skipfile <file> Name of a file containing test names
or regexp patterns
that should be skipped (one per line)."
"--skiptest <
name> Name of a file containing test names that should be skipped (one per line)
."
"--skiptest <
test> Test name or regexp pattern to skip. This option can be repeated
."
"--tags <tags> Run only tests having specified tags or not having '-' prefixed tags."
"--tags <tags> Run only tests having specified tags or not having '-' prefixed tags."
"--dont-clean Don't delete redis log files after the run."
"--dont-clean Don't delete redis log files after the run."
"--no-latency Skip latency measurements and validation by some tests."
"--no-latency Skip latency measurements and validation by some tests."
...
...
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