]> git.localhorst.tv Git - blank.git/commitdiff
make test binary exit with failure on failed tests
authorDaniel Karbach <daniel.karbach@localhorst.tv>
Mon, 21 Nov 2016 13:53:16 +0000 (14:53 +0100)
committerDaniel Karbach <daniel.karbach@localhorst.tv>
Mon, 21 Nov 2016 13:53:16 +0000 (14:53 +0100)
tst/test.cpp

index ff1ce710c25c80912d4ab90ed2fd18e61a8d75fd..f95ead372d3ce212faa3b17872aae9dd6a5fa38e 100644 (file)
@@ -9,8 +9,9 @@ int main(int, char **) {
        TestRunner runner;
        TestFactoryRegistry &registry = TestFactoryRegistry::getRegistry();
        runner.addTest(registry.makeTest());
-       runner.run();
-
-       return 0;
-
+       if (runner.run()) {
+               return 0;
+       } else {
+               return 1;
+       }
 }