Index: src/core/test/simulator-test-suite.cc |
=================================================================== |
--- a/src/core/test/simulator-test-suite.cc |
+++ b/src/core/test/simulator-test-suite.cc |
@@ -26,26 +26,59 @@ |
using namespace ns3; |
+/** |
+ * \ingroup core-test |
+ * \ingroup tests |
+ * |
+ * \brief Simulator events test |
+ */ |
class SimulatorEventsTestCase : public TestCase |
{ |
public: |
+ /** |
+ * Constructor |
+ * |
+ * \param schedulerFactory the scheduler |
+ */ |
SimulatorEventsTestCase (ObjectFactory schedulerFactory); |
virtual void DoRun (void); |
+ /** |
+ * Event A test function |
+ * \param a event # |
+ */ |
void EventA (int a); |
+ /** |
+ * Event B test function |
+ * \param b event # |
+ */ |
void EventB (int b); |
+ /** |
+ * Event C test function |
+ * \param c event # |
+ */ |
void EventC (int c); |
+ /** |
+ * Event D test function |
+ * \param d event # |
+ */ |
void EventD (int d); |
+ /// test function |
void Eventfoo0 (void); |
+ /** |
+ * Now time us function |
+ * \returns now time in us |
+ */ |
uint64_t NowUs (void); |
+ /// test function |
void destroy (void); |
- bool m_b; |
- bool m_a; |
- bool m_c; |
- bool m_d; |
- EventId m_idC; |
- bool m_destroy; |
- EventId m_destroyId; |
- ObjectFactory m_schedulerFactory; |
+ bool m_b; ///< test value |
+ bool m_a; ///< test value |
+ bool m_c; ///< test value |
+ bool m_d; ///< test value |
+ EventId m_idC; ///< event I |
+ bool m_destroy; ///< destroy flag |
+ EventId m_destroyId; ///< event ID |
+ ObjectFactory m_schedulerFactory; ///< schedule factory |
}; |
SimulatorEventsTestCase::SimulatorEventsTestCase (ObjectFactory schedulerFactory) |
@@ -168,48 +201,88 @@ |
NS_TEST_EXPECT_MSG_EQ (m_destroy, true, "Event should have run"); |
} |
+/** |
+ * \ingroup core-test |
+ * \ingroup tests |
+ * |
+ * \brief Simulator template test |
+ */ |
class SimulatorTemplateTestCase : public TestCase |
{ |
public: |
SimulatorTemplateTestCase (); |
// only here for testing of Ptr<> |
+ /// reference count function |
void Ref (void) const {} |
+ /// unreference count function |
void Unref (void) const {} |
private: |
virtual void DoRun (void); |
+ /// zero parameter test function |
void bar0 (void) {} |
+ /// one parameter test function |
void bar1 (int) {} |
+ /// two parameter test function |
void bar2 (int, int) {} |
+ /// three parameter test function |
void bar3 (int, int, int) {} |
+ /// four parameter test function |
void bar4 (int, int, int, int) {} |
+ /// five parameter test function |
void bar5 (int, int, int, int, int) {} |
+ /// one parameter reference test function |
void baz1 (int &) {} |
+ /// two parameter reference test function |
void baz2 (int &, int &) {} |
+ /// three parameter reference test function |
void baz3 (int &, int &, int &) {} |
+ /// four parameter reference test function |
void baz4 (int &, int &, int &, int &) {} |
+ /// five parameter reference test function |
void baz5 (int &, int &, int &, int &, int &) {} |
+ /// one parameter const reference test function |
void cbaz1 (const int &) {} |
+ /// two parameter const reference test function |
void cbaz2 (const int &, const int &) {} |
+ /// three parameter const reference test function |
void cbaz3 (const int &, const int &, const int &) {} |
+ /// four parameter const reference test function |
void cbaz4 (const int &, const int &, const int &, const int &) {} |
+ /// five parameter const reference test function |
void cbaz5 (const int &, const int &, const int &, const int &, const int &) {} |
+ /// zero parameter test const function |
void bar0c (void) const {} |
+ /// one parameter test const function |
void bar1c (int) const {} |
+ /// two parameter test const function |
void bar2c (int, int) const {} |
+ /// three parameter test const function |
void bar3c (int, int, int) const {} |
+ /// four parameter test const function |
void bar4c (int, int, int, int) const {} |
+ /// five parameter test const function |
void bar5c (int, int, int, int, int) const {} |
+ /// one parameter reference test const function |
void baz1c (int &) const {} |
+ /// two parameter reference test const function |
void baz2c (int &, int &) const {} |
+ /// three parameter reference test const function |
void baz3c (int &, int &, int &) const {} |
+ /// four parameter reference test const function |
void baz4c (int &, int &, int &, int &) const {} |
+ /// five parameter reference test const function |
void baz5c (int &, int &, int &, int &, int &) const {} |
+ /// one parameter const reference test const function |
void cbaz1c (const int &) const {} |
+ /// two parameter const reference test const function |
void cbaz2c (const int &, const int &) const {} |
+ /// three parameter const reference test const function |
void cbaz3c (const int &, const int &, const int &) const {} |
+ /// four parameter const reference test const function |
void cbaz4c (const int &, const int &, const int &, const int &) const {} |
+ /// five parameter const reference test const function |
void cbaz5c (const int &, const int &, const int &, const int &, const int &) const {} |
}; |
@@ -459,6 +532,12 @@ |
Simulator::Destroy (); |
} |
+/** |
+ * \ingroup core-test |
+ * \ingroup tests |
+ * |
+ * \brief Simulator test suite |
+ */ |
class SimulatorTestSuite : public TestSuite |
{ |
public: |
@@ -476,4 +555,4 @@ |
factory.SetTypeId (CalendarScheduler::GetTypeId ()); |
AddTestCase (new SimulatorEventsTestCase (factory), TestCase::QUICK); |
} |
-} g_simulatorTestSuite; |
+} g_simulatorTestSuite; ///< the test suite |