added more tests to increase test coverage
[senf.git] / PPI / SocketSink.test.cc
index 0114565..fa2f062 100644 (file)
@@ -47,7 +47,7 @@ namespace debug = module::debug;
 
 namespace {
     void timeout() {
-        senf::Scheduler::instance().terminate();
+        senf::scheduler::terminate();
     }
 }
 
@@ -84,8 +84,9 @@ BOOST_AUTO_UNIT_TEST(activeSocketSink)
 
     senf::UDPv4ClientSocketHandle inputSocket;
     inputSocket.bind(senf::INet4SocketAddress("localhost:44344"));
-    senf::Scheduler::instance().timeout(
-        senf::ClockService::now() + senf::ClockService::milliseconds(100), &timeout);
+    senf::scheduler::TimerEvent timer (
+        "activeSocketSink test timer", &timeout,
+        senf::ClockService::now() + senf::ClockService::milliseconds(100));
     source.submit(p);
     senf::ppi::run();