You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
425 B
23 lines
425 B
_testPassCount=0; |
|
_testTotalCount=0; |
|
|
|
function it() { |
|
local exitCode=$?; |
|
local message=$1; |
|
local status; |
|
|
|
_testTotalCount=$((_testTotalCount+1)); |
|
|
|
if [ "$exitCode" -eq 0 ]; then |
|
status='✓'; |
|
_testPassCount=$((_testPassCount+1)); |
|
else |
|
status='✗'; |
|
fi; |
|
|
|
printf '%s %s\n' "$status" "$message"; |
|
} |
|
|
|
function testSummary() { |
|
printf 'Passed: %s of %s tests\n' "$_testPassCount" "$_testTotalCount"; |
|
}
|
|
|