Return proper exit code.

Return exit code 1 when there are failure or error tests.
This fixes the problem with Travis and other CI who takes
the exit code to define if tests run ok.
Merge pull request #3 from eMancu/fix_exit_status_on_failure_tests

Return proper exit code.