File tree Expand file tree Collapse file tree 3 files changed +31
-3
lines changed Expand file tree Collapse file tree 3 files changed +31
-3
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,9 @@ source $PROJECT_ROOT/ci/test/env/cn10k.env
6
6
7
7
DAO_SUITE=dao-virtio
8
8
9
+ # Continue testing regardless of failure
10
+ CONTINUE_ON_FAILURE=1
11
+
9
12
# List of perf tests to be run.
10
13
RUN_TESTS="
11
14
virtio_l2fwd_perf
Original file line number Diff line number Diff line change @@ -55,6 +55,12 @@ CMD_EXTRA_ARGS=""
55
55
# List of tests to be run. If list is empty all tests are run except those in SKIP_TESTS.
56
56
RUN_TESTS=${RUN_TESTS:- }
57
57
58
+ # Continue testing regardless of failure
59
+ CONTINUE_ON_FAILURE=${CONTINUE_ON_FAILURE:- }
60
+
61
+ # File to save status into
62
+ STATUS_OUTFILE=${STATUS_OUTFILE:- }
63
+
58
64
FIXME_SKIP_TESTS=" "
59
65
60
66
DEFAULT_SKIP_TESTS="
Original file line number Diff line number Diff line change @@ -89,6 +89,9 @@ function run_all_tests()
89
89
{
90
90
local tst
91
91
local res
92
+ local failed_tests=" "
93
+ local passed_tests=" "
94
+ local skipped_tests=" "
92
95
local test_num=0
93
96
94
97
# Errors will be handled inline. No need for sig handler
@@ -100,22 +103,38 @@ function run_all_tests()
100
103
test_num=$(( test_num + 1 ))
101
104
test_enabled $test_num
102
105
res=$?
106
+ tst=$( get_test_name $test_num )
103
107
if [[ $res == 77 ]]; then
108
+ skipped_tests=" ${skipped_tests}${tst} #"
104
109
continue
105
110
fi
106
111
if [[ $res -ne 0 ]]; then
107
112
break
108
113
fi
109
114
110
- tst=$( get_test_name $test_num )
111
-
112
115
# Run the tests
113
116
run_test $tst
114
117
res=$?
115
118
if [[ $res -ne 0 ]] && [[ $res -ne 77 ]] ; then
116
- test_exit -1 " FAILURE: Test $tst failed"
119
+ failed_tests=" ${failed_tests}${tst} #"
120
+ if [[ -n $CONTINUE_ON_FAILURE ]]; then
121
+ echo " FAILURE: Test $tst failed"
122
+ else
123
+ test_exit -1 " FAILURE: Test $tst failed"
124
+ fi
125
+ else
126
+ passed_tests=" ${passed_tests}${tst} #"
117
127
fi
118
128
done
129
+
130
+ if [[ -n $STATUS_OUTFILE ]] ; then
131
+ echo " FAILED: $failed_tests " > $STATUS_OUTFILE
132
+ echo " PASSED: $passed_tests " >> $STATUS_OUTFILE
133
+ echo " SKIPPED: $skipped_tests " >> $STATUS_OUTFILE
134
+ fi
135
+ if [[ -n $failed_tests ]]; then
136
+ test_exit -1 " FAILURE: Test(s) [$failed_tests ] failed"
137
+ fi
119
138
}
120
139
121
140
function test_exit()
You can’t perform that action at this time.
0 commit comments