Tests exit codes