diff --git a/tests/core/scheduler.cpp b/tests/core/scheduler.cpp
index 77ca1e9..d6b51fa 100644
--- a/tests/core/scheduler.cpp
+++ b/tests/core/scheduler.cpp
@@ -21,7 +21,7 @@
     , count4(0)
   {
   }
-    
+
   void
   event1()
   {
@@ -47,7 +47,7 @@
   {
     ++count4;
   }
-  
+
   int count1;
   int count2;
   int count3;
@@ -56,23 +56,23 @@
 
 BOOST_FIXTURE_TEST_CASE(Events, SchedulerFixture)
 {
-  boost::asio::io_service io; 
+  resetGlobalIoService();
 
-  Scheduler scheduler(io);
-  scheduler.scheduleEvent(time::seconds(0.5), bind(&SchedulerFixture::event1, this));
-  
-  EventId i = scheduler.scheduleEvent(time::seconds(1.0), bind(&SchedulerFixture::event2, this));
-  scheduler.cancelEvent(i);
+  scheduler::schedule(time::seconds(0.5), bind(&SchedulerFixture::event1, this));
 
-  scheduler.scheduleEvent(time::seconds(0.25), bind(&SchedulerFixture::event3, this));
+  EventId i = scheduler::schedule(time::seconds(1.0), bind(&SchedulerFixture::event2, this));
+  scheduler::cancel(i);
 
-  i = scheduler.scheduleEvent(time::seconds(0.05), bind(&SchedulerFixture::event2, this));
-  scheduler.cancelEvent(i);
+  scheduler::schedule(time::seconds(0.25), bind(&SchedulerFixture::event3, this));
 
-  i = scheduler.schedulePeriodicEvent(time::seconds(0.3), time::seconds(0.1), bind(&SchedulerFixture::event4, this));
-  scheduler.scheduleEvent(time::seconds(1), bind(&Scheduler::cancelEvent, &scheduler, i));
-  
-  io.run();
+  i = scheduler::schedule(time::seconds(0.05), bind(&SchedulerFixture::event2, this));
+  scheduler::cancel(i);
+
+  // TODO deprecate periodic event
+  i = scheduler::getGlobalScheduler().schedulePeriodicEvent(time::seconds(0.3), time::seconds(0.1), bind(&SchedulerFixture::event4, this));
+  scheduler::schedule(time::seconds(1), bind(&scheduler::cancel, i));
+
+  getGlobalIoService().run();
 
   BOOST_CHECK_EQUAL(count1, 1);
   BOOST_CHECK_EQUAL(count2, 0);
@@ -82,37 +82,29 @@
 
 BOOST_AUTO_TEST_CASE(CancelEmptyEvent)
 {
-  boost::asio::io_service io; 
-  Scheduler scheduler(io);
-  
   EventId i;
-  scheduler.cancelEvent(i);
+  scheduler::cancel(i);
 }
 
 struct SelfCancelFixture
 {
-  SelfCancelFixture()
-    : m_scheduler(m_io)
-  {
-  }
-  
   void
   cancelSelf()
   {
-    m_scheduler.cancelEvent(m_selfEventId);
+    scheduler::cancel(m_selfEventId);
   }
-  
-  boost::asio::io_service m_io; 
-  Scheduler m_scheduler;
+
   EventId m_selfEventId;
 };
 
 BOOST_FIXTURE_TEST_CASE(SelfCancel, SelfCancelFixture)
 {
-  m_selfEventId = m_scheduler.scheduleEvent(time::seconds(0.1),
-                                            bind(&SelfCancelFixture::cancelSelf, this));
-  
-  BOOST_REQUIRE_NO_THROW(m_io.run());
+  resetGlobalIoService();
+
+  m_selfEventId = scheduler::schedule(time::seconds(0.1),
+                                      bind(&SelfCancelFixture::cancelSelf, this));
+
+  BOOST_REQUIRE_NO_THROW(getGlobalIoService().run());
 }
 
 BOOST_AUTO_TEST_SUITE_END()
diff --git a/tests/core/time.cpp b/tests/core/time.cpp
deleted file mode 100644
index 6d0db3f..0000000
--- a/tests/core/time.cpp
+++ /dev/null
@@ -1,47 +0,0 @@
-/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (C) 2014 Named Data Networking Project
- * See COPYING for copyright and distribution information.
- */
-
-#include "core/time.hpp"
-
-#include <boost/test/unit_test.hpp>
-
-namespace nfd {
-
-BOOST_AUTO_TEST_SUITE(CoreTime)
-
-BOOST_AUTO_TEST_CASE(Now)
-{
-  time::Point p1 = time::now();
-  time::Point p2 = time::now();
-  BOOST_CHECK_LE(p1, p2);
-}
-
-BOOST_AUTO_TEST_CASE(Operations)
-{
-  // helpers
-  BOOST_CHECK_GT(time::seconds(1), time::milliseconds(1));
-  BOOST_CHECK_GT(time::milliseconds(1), time::microseconds(1));
-  BOOST_CHECK_GT(time::microseconds(1), time::nanoseconds(1));
-  
-  // duration operations + helpers
-  BOOST_CHECK_EQUAL(time::seconds(8) + time::microseconds(101), time::nanoseconds(8000101000));
-  BOOST_CHECK_EQUAL(time::seconds(7) - time::milliseconds(234), time::microseconds(6766000));
-
-  // point operations
-  time::Point p1 = time::now();
-  time::Point p2 = p1 + time::milliseconds(10000);
-  time::Point p3 = p2 - time::microseconds(5000000);
-  BOOST_CHECK_LE(p1, p2);
-  BOOST_CHECK_LE(p1, p3);
-  BOOST_CHECK_LE(p3, p2);
-  
-  BOOST_CHECK_EQUAL(p2 - p1, time::seconds(10));
-  BOOST_CHECK_EQUAL(p3 - p1, time::seconds(5));
-}
-
-BOOST_AUTO_TEST_SUITE_END()
-
-} // namespace nfd
diff --git a/tests/fw/broadcast-strategy.cpp b/tests/fw/broadcast-strategy.cpp
index 3976f62..15928be 100644
--- a/tests/fw/broadcast-strategy.cpp
+++ b/tests/fw/broadcast-strategy.cpp
@@ -16,8 +16,8 @@
 
 BOOST_AUTO_TEST_CASE(ForwardTwo)
 {
-  boost::asio::io_service io;
-  Forwarder forwarder(io);
+  resetGlobalIoService();
+  Forwarder forwarder;
   typedef StrategyTester<fw::BroadcastStrategy> BroadcastStrategyTester;
   BroadcastStrategyTester strategy(forwarder);
 
@@ -60,8 +60,8 @@
 
 BOOST_AUTO_TEST_CASE(Rebuff)
 {
-  boost::asio::io_service io;
-  Forwarder forwarder(io);
+  resetGlobalIoService();
+  Forwarder forwarder;
   typedef StrategyTester<fw::BroadcastStrategy> BroadcastStrategyTester;
   BroadcastStrategyTester strategy(forwarder);
 
diff --git a/tests/fw/forwarder.cpp b/tests/fw/forwarder.cpp
index e066f52..daa80c7 100644
--- a/tests/fw/forwarder.cpp
+++ b/tests/fw/forwarder.cpp
@@ -18,14 +18,14 @@
     : m_ioService(ioService)
   {
   }
-  
+
   virtual void
   sendInterest(const Interest& interest)
   {
     m_sentInterests.push_back(interest);
     m_ioService.stop();
   }
-  
+
   virtual void
   sendData(const Data& data)
   {
@@ -43,7 +43,7 @@
   {
     onReceiveInterest(interest);
   }
-  
+
   void
   receiveData(const Data& data)
   {
@@ -62,15 +62,15 @@
 
 BOOST_AUTO_TEST_CASE(AddRemoveFace)
 {
-  boost::asio::io_service io;
-  Forwarder forwarder(io);
-  
+  resetGlobalIoService();
+  Forwarder forwarder;
+
   shared_ptr<Face> face1 = make_shared<DummyFace>();
   shared_ptr<Face> face2 = make_shared<DummyFace>();
-  
+
   BOOST_CHECK_EQUAL(face1->getId(), INVALID_FACEID);
   BOOST_CHECK_EQUAL(face2->getId(), INVALID_FACEID);
-  
+
   forwarder.addFace(face1);
   forwarder.addFace(face2);
 
@@ -87,34 +87,35 @@
 
 BOOST_AUTO_TEST_CASE(SimpleExchange)
 {
+  resetGlobalIoService();
+  boost::asio::io_service& io = getGlobalIoService();
+  Forwarder forwarder;
+
   Name nameA  ("ndn:/A");
   Name nameAB ("ndn:/A/B");
   Name nameABC("ndn:/A/B/C");
   Interest interestAB(nameAB);
   interestAB.setInterestLifetime(4000);
   Data dataABC(nameABC);
-  
-  boost::asio::io_service io;
-  Forwarder forwarder(io);
 
   shared_ptr<ForwarderTestFace> face1 = make_shared<ForwarderTestFace>(boost::ref(io));
   shared_ptr<ForwarderTestFace> face2 = make_shared<ForwarderTestFace>(boost::ref(io));
   forwarder.addFace(face1);
   forwarder.addFace(face2);
-  
+
   Fib& fib = forwarder.getFib();
   std::pair<shared_ptr<fib::Entry>, bool> fibInsertResult =
     fib.insert(Name("ndn:/A"));
   shared_ptr<fib::Entry> fibEntry = fibInsertResult.first;
   fibEntry->addNextHop(face2, 0);
-  
+
   face1->receiveInterest(interestAB);
   io.run();
   io.reset();
   BOOST_REQUIRE_EQUAL(face2->m_sentInterests.size(), 1);
   BOOST_CHECK(face2->m_sentInterests[0].getName().equals(nameAB));
   BOOST_CHECK_EQUAL(face2->m_sentInterests[0].getIncomingFaceId(), face1->getId());
-  
+
   face2->receiveData(dataABC);
   io.run();
   io.reset();
@@ -126,9 +127,7 @@
 class ScopeLocalhostTestForwarder : public Forwarder
 {
 public:
-  explicit
-  ScopeLocalhostTestForwarder(boost::asio::io_service& ioService)
-    : Forwarder(ioService)
+  ScopeLocalhostTestForwarder()
   {
   }
 
@@ -155,33 +154,33 @@
 
 BOOST_AUTO_TEST_CASE(ScopeLocalhost)
 {
-  boost::asio::io_service io;
-  ScopeLocalhostTestForwarder forwarder(io);
+  resetGlobalIoService();
+  ScopeLocalhostTestForwarder forwarder;
   shared_ptr<DummyLocalFace> face1 = make_shared<DummyLocalFace>();
   shared_ptr<DummyFace>      face2 = make_shared<DummyFace>();
   forwarder.addFace(face1);
   forwarder.addFace(face2);
-  
+
   // local face, /localhost: OK
   forwarder.m_dispatchToStrategy_count = 0;
   forwarder.onIncomingInterest(*face1, Interest(Name("/localhost/A1")));
   BOOST_CHECK_EQUAL(forwarder.m_dispatchToStrategy_count, 1);
-  
+
   // non-local face, /localhost: violate
   forwarder.m_dispatchToStrategy_count = 0;
   forwarder.onIncomingInterest(*face2, Interest(Name("/localhost/A2")));
   BOOST_CHECK_EQUAL(forwarder.m_dispatchToStrategy_count, 0);
-  
+
   // local face, non-/localhost: OK
   forwarder.m_dispatchToStrategy_count = 0;
   forwarder.onIncomingInterest(*face1, Interest(Name("/A3")));
   BOOST_CHECK_EQUAL(forwarder.m_dispatchToStrategy_count, 1);
-  
+
   // non-local face, non-/localhost: OK
   forwarder.m_dispatchToStrategy_count = 0;
   forwarder.onIncomingInterest(*face2, Interest(Name("/A4")));
   BOOST_CHECK_EQUAL(forwarder.m_dispatchToStrategy_count, 1);
-  
+
   // local face, /localhost: OK
   forwarder.m_onDataUnsolicited_count = 0;
   forwarder.onIncomingData(*face1, Data(Name("/localhost/B1")));
@@ -191,7 +190,7 @@
   forwarder.m_onDataUnsolicited_count = 0;
   forwarder.onIncomingData(*face2, Data(Name("/localhost/B2")));
   BOOST_CHECK_EQUAL(forwarder.m_onDataUnsolicited_count, 0);
-  
+
   // local face, non-/localhost: OK
   forwarder.m_onDataUnsolicited_count = 0;
   forwarder.onIncomingData(*face1, Data(Name("/B3")));
diff --git a/tests/table/measurements-accessor.cpp b/tests/table/measurements-accessor.cpp
index 789d02a..9738701 100644
--- a/tests/table/measurements-accessor.cpp
+++ b/tests/table/measurements-accessor.cpp
@@ -21,10 +21,10 @@
     : Strategy(forwarder)
   {
   }
-  
+
   virtual
   ~MeasurementsAccessorTestStrategy()
-  
+
   {
   }
 
@@ -36,7 +36,7 @@
   {
     BOOST_ASSERT(false);
   }
-  
+
 public: // accessors
   MeasurementsAccessor&
   getMeasurements_accessor()
@@ -47,36 +47,37 @@
 
 BOOST_AUTO_TEST_CASE(Access)
 {
-  boost::asio::io_service ioService;
-  Forwarder forwarder(ioService);
+  resetGlobalIoService();
+  Forwarder forwarder;
+
   shared_ptr<MeasurementsAccessorTestStrategy> strategy1 =
     make_shared<MeasurementsAccessorTestStrategy>(boost::ref(forwarder));
   shared_ptr<MeasurementsAccessorTestStrategy> strategy2 =
     make_shared<MeasurementsAccessorTestStrategy>(boost::ref(forwarder));
-  
+
   Name nameRoot("ndn:/");
   Name nameA   ("ndn:/A");
   Name nameAB  ("ndn:/A/B");
   Name nameABC ("ndn:/A/B/C");
   Name nameAD  ("ndn:/A/D");
-  
+
   Fib& fib = forwarder.getFib();
   fib.insert(nameRoot).first->setStrategy(strategy1);
   fib.insert(nameA   ).first->setStrategy(strategy2);
   fib.insert(nameAB  ).first->setStrategy(strategy1);
-  
+
   MeasurementsAccessor& accessor1 = strategy1->getMeasurements_accessor();
   MeasurementsAccessor& accessor2 = strategy2->getMeasurements_accessor();
-  
+
   BOOST_CHECK_EQUAL(static_cast<bool>(accessor1.get(nameRoot)), true);
   BOOST_CHECK_EQUAL(static_cast<bool>(accessor1.get(nameA   )), false);
   BOOST_CHECK_EQUAL(static_cast<bool>(accessor1.get(nameAB  )), true);
   BOOST_CHECK_EQUAL(static_cast<bool>(accessor1.get(nameABC )), true);
   BOOST_CHECK_EQUAL(static_cast<bool>(accessor1.get(nameAD  )), false);
-  
+
   shared_ptr<measurements::Entry> entryRoot = forwarder.getMeasurements().get(nameRoot);
   BOOST_CHECK_NO_THROW(accessor1.getParent(entryRoot));
-  
+
   BOOST_CHECK_EQUAL(static_cast<bool>(accessor2.get(nameRoot)), false);
   BOOST_CHECK_EQUAL(static_cast<bool>(accessor2.get(nameA   )), true);
   BOOST_CHECK_EQUAL(static_cast<bool>(accessor2.get(nameAB  )), false);
diff --git a/tests/table/measurements.cpp b/tests/table/measurements.cpp
index 09874a0..4643fb8 100644
--- a/tests/table/measurements.cpp
+++ b/tests/table/measurements.cpp
@@ -14,13 +14,13 @@
 
 BOOST_AUTO_TEST_CASE(Get_Parent)
 {
+  resetGlobalIoService();
+  Measurements measurements;
+
   Name name0;
   Name nameA ("ndn:/A");
   Name nameAB("ndn:/A/B");
 
-  boost::asio::io_service ioService;
-  Measurements measurements(ioService);
-
   shared_ptr<measurements::Entry> entryAB = measurements.get(nameAB);
   BOOST_REQUIRE(static_cast<bool>(entryAB));
   BOOST_CHECK_EQUAL(entryAB->getName(), nameAB);
