]> git.localhorst.tv Git - blank.git/blobdiff - tst/integration/ServerTest.cpp
timeouts reading from spawned processes
[blank.git] / tst / integration / ServerTest.cpp
index fbec21a70f7cd7d9fe96929c1f717129816f61ee..8fe7788a6849ce2c5efb861180caa76299c6f9f6 100644 (file)
@@ -1,6 +1,6 @@
 #include "ServerTest.hpp"
 
-#include "TestServer.hpp"
+#include "TestInstance.hpp"
 
 CPPUNIT_TEST_SUITE_REGISTRATION(blank::test::ServerTest);
 
@@ -9,16 +9,20 @@ namespace blank {
 namespace test {
 
 void ServerTest::setUp() {
-
+       instance.reset(new TestInstance({ "--server" }, true));
+       instance->AssertRunning();
 }
 
 void ServerTest::tearDown() {
-
+       std::unique_ptr<TestInstance> inst(std::move(instance));
+       inst->Terminate();
+       inst->AssertExitStatus(0);
+       inst->AssertNoError();
 }
 
 
 void ServerTest::testStartup() {
-       TestServer server;
+       // setUp and testDown do all the tests
 }
 
 }