Follow ndn::Scheduler API changes

Refs: #4883
Change-Id: I94f9096225a26accbdc9e2dc37462f6d7c6474ef
diff --git a/tests/unit/tcp-bulk-insert-handle.cpp b/tests/unit/tcp-bulk-insert-handle.cpp
index ad82c10..48d1ae3 100644
--- a/tests/unit/tcp-bulk-insert-handle.cpp
+++ b/tests/unit/tcp-bulk-insert-handle.cpp
@@ -84,8 +84,7 @@
     : scheduler(ioService)
     , bulkInserter(ioService, *handle)
   {
-    guardEvent = scheduler.scheduleEvent(ndn::time::seconds(2),
-                                         std::bind(&TcpBulkInsertFixture::fail, this, "Test timed out"));
+    guardEvent = scheduler.schedule(2_s, std::bind(&TcpBulkInsertFixture::fail, this, "Test timed out"));
   }
 
   virtual void
@@ -118,12 +117,10 @@
     }
 
     if (isFinal) {
-      scheduler.cancelEvent(guardEvent);
+      guardEvent.cancel();
 
       // In case there are some outstanding handlers
-      // ioService.post(bind(&TcpBulkInsertFixture::stop, this));
-      scheduler.scheduleEvent(ndn::time::seconds(1),
-                              std::bind(&TcpBulkInsertFixture::stop, this));
+      scheduler.schedule(1_s, [this] { stop(); });
     }
   }
 
@@ -171,7 +168,6 @@
   }
 }
 
-
 BOOST_AUTO_TEST_SUITE_END()
 
 } // namespace tests