projects
/
libstick.git
/ commitdiff
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9c6496a
)
Enable ctest, fix exit status of tests/tests
author
Stefan Huber <shuber@sthu.org>
Tue, 12 Nov 2013 16:18:12 +0000
(17:18 +0100)
committer
Stefan Huber <shuber@sthu.org>
Tue, 12 Nov 2013 16:18:12 +0000
(17:18 +0100)
CMakeLists.txt
patch
|
blob
|
history
tests/main.cc
patch
|
blob
|
history
diff --git
a/CMakeLists.txt
b/CMakeLists.txt
index e6153031405e3cf7b57e2e334c62b27e54c42e7f..8969cb30776f56573a0ad2ceb95aa9ac4f12924c 100644
(file)
--- a/
CMakeLists.txt
+++ b/
CMakeLists.txt
@@
-28,6
+28,8
@@
add_subdirectory(lib)
if(WITH_UNITTESTS)
add_subdirectory(tests)
+ enable_testing()
+ add_test(NAME unittests COMMAND tests)
endif()
diff --git
a/tests/main.cc
b/tests/main.cc
index 0b3dd996f1af959242a3b2efa6374e821c79b339..6016b3b511c6c2e707186bfe085c98f4526e0432 100644
(file)
--- a/
tests/main.cc
+++ b/
tests/main.cc
@@
-19,6
+19,8
@@
int main(int argc, char* argv[]) {
ts.add(auto_ptr<Test::Suite>(new persistence_TestSuite));
Test::TextOutput output(Test::TextOutput::Verbose);
- return ts.run(output);
+ if (ts.run(output))
+ return EXIT_SUCCESS;
+ return EXIT_FAILURE;
}