table: dead Nonce list
refs #1953
Change-Id: I65eb2346716dd47bcf1850c832e37e5354042fd0
diff --git a/tests/limited-io.hpp b/tests/limited-io.hpp
index cb81247..92aef02 100644
--- a/tests/limited-io.hpp
+++ b/tests/limited-io.hpp
@@ -1,11 +1,12 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/**
- * Copyright (c) 2014 Regents of the University of California,
- * Arizona Board of Regents,
- * Colorado State University,
- * University Pierre & Marie Curie, Sorbonne University,
- * Washington University in St. Louis,
- * Beijing Institute of Technology
+ * Copyright (c) 2014, Regents of the University of California,
+ * Arizona Board of Regents,
+ * Colorado State University,
+ * University Pierre & Marie Curie, Sorbonne University,
+ * Washington University in St. Louis,
+ * Beijing Institute of Technology,
+ * The University of Memphis
*
* This file is part of NFD (Named Data Networking Forwarding Daemon).
* See AUTHORS.md for complete list of NFD authors and contributors.
@@ -20,7 +21,7 @@
*
* You should have received a copy of the GNU General Public License along with
* NFD, e.g., in COPYING.md file. If not, see <http://www.gnu.org/licenses/>.
- **/
+ */
#ifndef NFD_TESTS_LIMITED_IO_HPP
#define NFD_TESTS_LIMITED_IO_HPP
@@ -33,7 +34,7 @@
/** \brief provides IO operations limit and/or time limit for unit testing
*/
-class LimitedIo
+class LimitedIo : noncopyable
{
public:
LimitedIo();
@@ -41,7 +42,7 @@
/// indicates why .run returns
enum StopReason
{
- /// g_io.run() runs normally because there's no work to do
+ /// g_io.run() returns normally because there's no work to do
NO_WORK,
/// .afterOp() has been invoked nOpsLimit times
EXCEED_OPS,
@@ -66,6 +67,16 @@
const std::exception&
getLastException() const;
+ /** \brief defer for specified duration
+ *
+ * equivalent to .run(UNLIMITED_OPS, d)
+ */
+ void
+ defer(const time::nanoseconds& d)
+ {
+ this->run(UNLIMITED_OPS, d);
+ }
+
private:
void
afterTimeout();