13de33a5dc
This change is a proof of concept on how to easily integrate existing tests from the tools/regression/ hierarchy into the /usr/tests/ test suite and on how to adapt them to the new layout for src. To achieve these goals, this change: - Moves tests from tools/regression/bin/<tool>/ to bin/<tool>/tests/. - Renames the previous regress.sh files to legacy_test.sh. - Adds Makefiles to build and install the tests and all their supporting data files into /usr/tests/bin/. - Plugs the legacy_test test programs into the test suite using the new TAP backend for Kyua (appearing in 0.8) so that the code of the test programs does not have to change. - Registers the new directories in the BSD.test.dist mtree file. Reviewed by: freebsd-testing Approved by: rpaulo (mentor)
107 lines
2.9 KiB
Plaintext
107 lines
2.9 KiB
Plaintext
# Generated by ./test-fnmatch -s 1, do not edit.
|
|
# $FreeBSD$
|
|
failures=
|
|
failed() { printf '%s\n' "Failed: $1 '$2' '$3'"; failures=x$failures; }
|
|
testmatch() { eval "case \$2 in ''$1) ;; *) failed testmatch \"\$@\";; esac"; }
|
|
testnomatch() { eval "case \$2 in ''$1) failed testnomatch \"\$@\";; esac"; }
|
|
testmatch '' ''
|
|
testmatch 'a' 'a'
|
|
testnomatch 'a' 'b'
|
|
testnomatch 'a' 'A'
|
|
testmatch '*' 'a'
|
|
testmatch '*' 'aa'
|
|
testmatch '*a' 'a'
|
|
testnomatch '*a' 'b'
|
|
testnomatch '*a*' 'b'
|
|
testmatch '*a*b*' 'ab'
|
|
testmatch '*a*b*' 'qaqbq'
|
|
testmatch '*a*bb*' 'qaqbqbbq'
|
|
testmatch '*a*bc*' 'qaqbqbcq'
|
|
testmatch '*a*bb*' 'qaqbqbb'
|
|
testmatch '*a*bc*' 'qaqbqbc'
|
|
testmatch '*a*bb' 'qaqbqbb'
|
|
testmatch '*a*bc' 'qaqbqbc'
|
|
testnomatch '*a*bb' 'qaqbqbbq'
|
|
testnomatch '*a*bc' 'qaqbqbcq'
|
|
testnomatch '*a*a*a*a*a*a*a*a*a*a*' 'aaaaaaaaa'
|
|
testmatch '*a*a*a*a*a*a*a*a*a*a*' 'aaaaaaaaaa'
|
|
testmatch '*a*a*a*a*a*a*a*a*a*a*' 'aaaaaaaaaaa'
|
|
testnomatch '.*.*.*.*.*.*.*.*.*.*' '.........'
|
|
testmatch '.*.*.*.*.*.*.*.*.*.*' '..........'
|
|
testmatch '.*.*.*.*.*.*.*.*.*.*' '...........'
|
|
testnomatch '*?*?*?*?*?*?*?*?*?*?*' '123456789'
|
|
testnomatch '??????????*' '123456789'
|
|
testnomatch '*??????????' '123456789'
|
|
testmatch '*?*?*?*?*?*?*?*?*?*?*' '1234567890'
|
|
testmatch '??????????*' '1234567890'
|
|
testmatch '*??????????' '1234567890'
|
|
testmatch '*?*?*?*?*?*?*?*?*?*?*' '12345678901'
|
|
testmatch '??????????*' '12345678901'
|
|
testmatch '*??????????' '12345678901'
|
|
testmatch '[x]' 'x'
|
|
testmatch '[*]' '*'
|
|
testmatch '[?]' '?'
|
|
testmatch '[' '['
|
|
testmatch '[[]' '['
|
|
testnomatch '[[]' 'x'
|
|
testnomatch '[*]' ''
|
|
testnomatch '[*]' 'x'
|
|
testnomatch '[?]' 'x'
|
|
testmatch '*[*]*' 'foo*foo'
|
|
testnomatch '*[*]*' 'foo'
|
|
testmatch '[0-9]' '0'
|
|
testmatch '[0-9]' '5'
|
|
testmatch '[0-9]' '9'
|
|
testnomatch '[0-9]' '/'
|
|
testnomatch '[0-9]' ':'
|
|
testnomatch '[0-9]' '*'
|
|
testnomatch '[!0-9]' '0'
|
|
testnomatch '[!0-9]' '5'
|
|
testnomatch '[!0-9]' '9'
|
|
testmatch '[!0-9]' '/'
|
|
testmatch '[!0-9]' ':'
|
|
testmatch '[!0-9]' '*'
|
|
testmatch '*[0-9]' 'a0'
|
|
testmatch '*[0-9]' 'a5'
|
|
testmatch '*[0-9]' 'a9'
|
|
testnomatch '*[0-9]' 'a/'
|
|
testnomatch '*[0-9]' 'a:'
|
|
testnomatch '*[0-9]' 'a*'
|
|
testnomatch '*[!0-9]' 'a0'
|
|
testnomatch '*[!0-9]' 'a5'
|
|
testnomatch '*[!0-9]' 'a9'
|
|
testmatch '*[!0-9]' 'a/'
|
|
testmatch '*[!0-9]' 'a:'
|
|
testmatch '*[!0-9]' 'a*'
|
|
testmatch '*[0-9]' 'a00'
|
|
testmatch '*[0-9]' 'a55'
|
|
testmatch '*[0-9]' 'a99'
|
|
testmatch '*[0-9]' 'a0a0'
|
|
testmatch '*[0-9]' 'a5a5'
|
|
testmatch '*[0-9]' 'a9a9'
|
|
testmatch '\*' '*'
|
|
testmatch '\?' '?'
|
|
testmatch '\[x]' '[x]'
|
|
testmatch '\[' '['
|
|
testmatch '\\' '\'
|
|
testmatch '*\**' 'foo*foo'
|
|
testnomatch '*\**' 'foo'
|
|
testmatch '*\\*' 'foo\foo'
|
|
testnomatch '*\\*' 'foo'
|
|
testmatch '\(' '('
|
|
testmatch '\a' 'a'
|
|
testnomatch '\*' 'a'
|
|
testnomatch '\?' 'a'
|
|
testnomatch '\*' '\*'
|
|
testnomatch '\?' '\?'
|
|
testnomatch '\[x]' '\[x]'
|
|
testnomatch '\[x]' '\x'
|
|
testnomatch '\[' '\['
|
|
testnomatch '\(' '\('
|
|
testnomatch '\a' '\a'
|
|
testmatch '.*' '.'
|
|
testmatch '.*' '..'
|
|
testmatch '.*' '.a'
|
|
testmatch 'a*' 'a.'
|
|
[ -z "$failures" ]
|