diff options
author | Arturo Borrero <arturo.borrero.glez@gmail.com> | 2016-05-11 14:39:33 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2016-05-13 11:36:12 +0200 |
commit | 684d62743dacfbc67b15e40dc7d6c922cae474a6 (patch) | |
tree | db2c15b11e61bf986754bd2b1ddfd4120aa744df /tests/shell/run-tests.sh | |
parent | 6d91c4d176c3235371333abc6044ad90bea21d6d (diff) |
tests/shell/run-tests.sh: execute tests in sorted order
Let's sort tests files before iterating over them.
Put the find string in a separated function so it's more readable.
Signed-off-by: Arturo Borrero Gonzalez <arturo.borrero.glez@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'tests/shell/run-tests.sh')
-rwxr-xr-x | tests/shell/run-tests.sh | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/shell/run-tests.sh b/tests/shell/run-tests.sh index 0bbb136b..057f11ef 100755 --- a/tests/shell/run-tests.sh +++ b/tests/shell/run-tests.sh @@ -61,10 +61,15 @@ kernel_cleanup() { nf_tables_ipv4 nf_tables_ipv6 nf_tables } +find_tests() { + ${FIND} ${TESTDIR} -executable -regex \ + .*${RETURNCODE_SEPARATOR}[0-9]+ | sort +} + echo "" ok=0 failed=0 -for testfile in $(${FIND} ${TESTDIR} -executable -regex .*${RETURNCODE_SEPARATOR}[0-9]+) +for testfile in $(find_tests) do kernel_cleanup |