tests.bash: return the trapped exit code
tests.bash: return the trapped exit code

The bash script tests.bash exits with exit code 1 if one of the tests
fail; it exits with exit code 0 otherwise.

The action set in trap should not mind about the exit code; it should
return the exit code it receives instead.

This commit returns the actual exitcode that is trapped. Additionally,
it outputs an error message if no errors happens and the exit code is
non-zero.

gazoo74/dosh