Skip to content

Commit

Permalink
Exit with failure codes when tests fail
Browse files Browse the repository at this point in the history
  • Loading branch information
agersant committed Aug 20, 2024
1 parent d329a1c commit 5fc3134
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion FrameMeter/src/test/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -166,5 +166,6 @@ int main(int32_t argc, char *argv[])
const std::string result_text = num_failure == 0 ? "\x1B[32mok\x1B[0m" : "\x1B[31mFAILED\x1B[0m";
std::cout << std::format("\ntest result: {}. {} passed; {} failed\n", result_text, num_success, num_failure);

return 0;
const int32_t exit_code = num_failure == 0 ? 0 : 1;
return exit_code;
}

0 comments on commit 5fc3134

Please sign in to comment.