Made it so that normal and after tests don't run if before tests failed.

This commit is contained in:
Pietro Gagliardi 2019-04-19 12:12:13 -04:00
parent da36b304f8
commit 6f3d45b107
1 changed files with 5 additions and 2 deletions

View File

@ -154,8 +154,11 @@ int testingMain(void)
anyFailed = 0;
testsetRun(&testsBefore, &anyFailed);
testsetRun(&tests, &anyFailed);
testsetRun(&testsAfter, &anyFailed);
// TODO print a warning that we skip the next stages if a prior stage failed?
if (!anyFailed)
testsetRun(&tests, &anyFailed);
if (!anyFailed)
testsetRun(&testsAfter, &anyFailed);
if (anyFailed) {
printf("FAIL\n");
return 1;