@@ -15,18 +15,18 @@ function console_results::render_result() {
1515 echo " "
1616
1717 local total_tests=0
18- (( total_tests+= $(state:: get_tests_passed)) )
19- (( total_tests+= $(state:: get_tests_skipped)) )
20- (( total_tests+= $(state:: get_tests_incomplete)) )
21- (( total_tests+= $(state:: get_tests_snapshot)) )
22- (( total_tests+= $(state:: get_tests_failed)) )
18+ (( total_tests += $(state:: get_tests_passed)) ) || true
19+ (( total_tests += $(state:: get_tests_skipped)) ) || true
20+ (( total_tests += $(state:: get_tests_incomplete)) ) || true
21+ (( total_tests += $(state:: get_tests_snapshot)) ) || true
22+ (( total_tests += $(state:: get_tests_failed)) ) || true
2323
2424 local total_assertions=0
25- (( total_assertions+= $(state:: get_assertions_passed)) )
26- (( total_assertions+= $(state:: get_assertions_skipped)) )
27- (( total_assertions+= $(state:: get_assertions_incomplete)) )
28- (( total_assertions+= $(state:: get_assertions_snapshot)) )
29- (( total_assertions+= $(state:: get_assertions_failed)) )
25+ (( total_assertions += $(state:: get_assertions_passed)) ) || true
26+ (( total_assertions += $(state:: get_assertions_skipped)) ) || true
27+ (( total_assertions += $(state:: get_assertions_incomplete)) ) || true
28+ (( total_assertions += $(state:: get_assertions_snapshot)) ) || true
29+ (( total_assertions += $(state:: get_assertions_failed)) ) || true
3030
3131 printf " %sTests: %s" " $_COLOR_FAINT " " $_COLOR_DEFAULT "
3232 if [[ " $( state::get_tests_passed) " -gt 0 ]] || [[ " $( state::get_assertions_passed) " -gt 0 ]]; then
@@ -111,7 +111,7 @@ function console_results::print_execution_time() {
111111}
112112
113113function console_results::print_successful_test() {
114- (( _SUCCESSFUL_TEST_COUNT++ ))
114+ (( _SUCCESSFUL_TEST_COUNT++ )) || true
115115
116116 if [[ " $SIMPLE_OUTPUT " == true ]]; then
117117 if (( _SUCCESSFUL_TEST_COUNT % 50 != 0 )) ; then
@@ -121,7 +121,7 @@ function console_results::print_successful_test() {
121121 fi
122122 else
123123 local test_name=$1
124- local data=$2
124+ local data=${2-}
125125
126126 if [[ -z " $data " ]]; then
127127 printf " %s✓ Passed%s: %s\n" " $_COLOR_PASSED " " $_COLOR_DEFAULT " " ${test_name} "
@@ -163,7 +163,7 @@ function console_results::print_failed_snapshot_test() {
163163
164164function console_results::print_skipped_test() {
165165 local test_name=$1
166- local reason=$2
166+ local reason=${2-}
167167
168168 printf " ${_COLOR_SKIPPED} ↷ Skipped${_COLOR_DEFAULT} : %s\n" " ${test_name} "
169169
@@ -174,7 +174,7 @@ function console_results::print_skipped_test() {
174174
175175function console_results::print_incomplete_test() {
176176 local test_name=$1
177- local pending=$2
177+ local pending=${2-}
178178
179179 printf " ${_COLOR_INCOMPLETE} ✒ Incomplete${_COLOR_DEFAULT} : %s\n" " ${test_name} "
180180
0 commit comments