Added conditional usage display for --pattern
This commit is contained in:
parent
07a5d9a600
commit
9374693b66
1 changed files with 9 additions and 2 deletions
11
src/main.c
11
src/main.c
|
@ -33,6 +33,14 @@
|
|||
|
||||
# define VERSION_MSG "Tests compiled with Criterion v" VERSION "\n"
|
||||
|
||||
#ifdef HAVE_FNMATCH
|
||||
# define PATTERN_USAGE \
|
||||
" --pattern [PATTERN]: run tests matching the " \
|
||||
"given pattern\n"
|
||||
#else
|
||||
# define PATTERN_USAGE
|
||||
#endif
|
||||
|
||||
# define USAGE \
|
||||
VERSION_MSG "\n" \
|
||||
"usage: %s OPTIONS\n" \
|
||||
|
@ -44,8 +52,7 @@
|
|||
" -f or --fail-fast: exit after the first failure\n" \
|
||||
" --ascii: don't use fancy unicode symbols " \
|
||||
"or colors in the output\n" \
|
||||
" --pattern [PATTERN]: run tests matching the " \
|
||||
"given pattern\n" \
|
||||
PATTERN_USAGE \
|
||||
" --tap: enables TAP formatting\n" \
|
||||
" --always-succeed: always exit with 0\n" \
|
||||
" --no-early-exit: do not exit the test worker " \
|
||||
|
|
Loading…
Add table
Reference in a new issue