Testing library separation: now not in launcher but isolated
[anna.git] / include / anna / testing / TestClock.hpp
diff --git a/include/anna/testing/TestClock.hpp b/include/anna/testing/TestClock.hpp
new file mode 100644 (file)
index 0000000..9ae98f4
--- /dev/null
@@ -0,0 +1,36 @@
+// ANNA - Anna is Not Nothingness Anymore                                                         //
+//                                                                                                //
+// (c) Copyright 2005-2015 Eduardo Ramos Testillano & Francisco Ruiz Rayo                         //
+//                                                                                                //
+// See project site at http://redmine.teslayout.com/projects/anna-suite                           //
+// See accompanying file LICENSE or copy at http://www.teslayout.com/projects/public/anna.LICENSE //
+
+
+#ifndef anna_testing_TestClock_hpp
+#define anna_testing_TestClock_hpp
+
+// Project
+#include <anna/core/core.hpp>
+#include <anna/timex/Clock.hpp>
+
+namespace anna {
+                
+namespace testing {
+
+class TestManager;
+
+class TestClock : public anna::timex::Clock {
+  TestManager *a_manager;
+
+public:
+  TestClock(const char *clockName, const anna::Millisecond & timeout, TestManager *manager)
+    : a_manager(manager), anna::timex::Clock(clockName, timeout) {;}
+
+  virtual bool tick() throw(anna::RuntimeException);
+};
+
+}
+}
+
+#endif
+