Public Member Functions | |
SixlowpanFragmentationTest () | |
~SixlowpanFragmentationTest () | |
virtual void | DoRun (void) |
Implementation to actually run this TestCase. More... | |
void | HandleReadClient (Ptr< Socket > socket) |
void | HandleReadIcmpClient (Ipv6Address icmpSource, uint8_t icmpTtl, uint8_t icmpType, uint8_t icmpCode, uint32_t icmpInfo) |
void | HandleReadServer (Ptr< Socket > socket) |
Ptr< Packet > | SendClient (void) |
void | SetFill (uint8_t *fill, uint32_t fillSize, uint32_t dataSize) |
void | StartClient (Ptr< Node > ClientNode) |
void | StartServer (Ptr< Node > ServerNode) |
Public Member Functions inherited from ns3::TestCase | |
virtual | ~TestCase () |
Destructor. More... | |
Private Attributes | |
uint8_t * | m_data |
uint32_t | m_dataSize |
uint8_t | m_icmpCode |
uint8_t | m_icmpType |
Ptr< Packet > | m_receivedPacketClient |
Ptr< Packet > | m_receivedPacketServer |
Ptr< Packet > | m_sentPacketClient |
uint32_t | m_size |
Ptr< Socket > | m_socketClient |
Ptr< Socket > | m_socketServer |
Additional Inherited Members | |
Public Types inherited from ns3::TestCase | |
enum | TestDuration { QUICK = 1, EXTENSIVE = 2, TAKES_FOREVER = 3 } |
How long the test takes to execute. More... | |
Protected Member Functions inherited from ns3::TestCase | |
TestCase (std::string name) | |
void | AddTestCase (TestCase *testCase) NS_DEPRECATED |
Add an individual child TestCase case to this TestCase. More... | |
void | AddTestCase (TestCase *testCase, enum TestDuration duration) |
Add an individual child TestCase to this test suite. More... | |
std::string | CreateDataDirFilename (std::string filename) |
std::string | CreateTempDirFilename (std::string filename) |
bool | GetErrorStatus (void) const NS_DEPRECATED |
std::string | GetName (void) const |
bool | IsStatusFailure (void) const |
bool | IsStatusSuccess (void) const |
bool | MustAssertOnFailure (void) const |
bool | MustContinueOnFailure (void) const |
void | ReportTestFailure (std::string cond, std::string actual, std::string limit, std::string message, std::string file, int32_t line) |
void | SetDataDir (std::string directory) |
Definition at line 85 of file sixlowpan-fragmentation-test.cc.
SixlowpanFragmentationTest::SixlowpanFragmentationTest | ( | ) |
Definition at line 121 of file sixlowpan-fragmentation-test.cc.
References m_data, m_dataSize, and m_socketServer.
SixlowpanFragmentationTest::~SixlowpanFragmentationTest | ( | ) |
Definition at line 129 of file sixlowpan-fragmentation-test.cc.
References m_data, and m_dataSize.
|
virtual |
Implementation to actually run this TestCase.
Subclasses should override this method to conduct their tests.
Implements ns3::TestCase.
Definition at line 258 of file sixlowpan-fragmentation-test.cc.
References ns3::Ipv6::AddAddress(), ns3::Node::AddDevice(), ns3::Ipv6::AddInterface(), AddInternetStack(), ns3::Packet::CopyData(), ns3::ErrorModel::Disable(), ns3::ErrorModel::Enable(), ns3::Node::GetId(), ns3::Socket::GetNode(), ns3::Object::GetObject(), ns3::Packet::GetSize(), m_data, m_icmpCode, m_icmpType, m_receivedPacketServer, m_socketClient, NS_TEST_EXPECT_MSG_EQ, ns3::BinaryErrorSixlowModel::Reset(), SendClient(), ns3::SimpleNetDevice::SetAddress(), ns3::ObjectBase::SetAttribute(), ns3::SimpleNetDevice::SetChannel(), ns3::ErrorChannelSixlow::SetDuplicateMode(), SetFill(), ns3::ErrorChannelSixlow::SetJumpingMode(), ns3::SimpleNetDevice::SetMtu(), ns3::SixLowPanNetDevice::SetNetDevice(), ns3::SimpleNetDevice::SetReceiveErrorModel(), ns3::Ipv6::SetUp(), StartClient(), and StartServer().
Definition at line 191 of file sixlowpan-fragmentation-test.cc.
References ns3::Packet::Copy(), m_receivedPacketClient, and ns3::Socket::RecvFrom().
Referenced by StartClient().
void SixlowpanFragmentationTest::HandleReadIcmpClient | ( | Ipv6Address | icmpSource, |
uint8_t | icmpTtl, | ||
uint8_t | icmpType, | ||
uint8_t | icmpCode, | ||
uint32_t | icmpInfo | ||
) |
Definition at line 205 of file sixlowpan-fragmentation-test.cc.
References m_icmpCode, and m_icmpType.
Referenced by StartClient().
Definition at line 157 of file sixlowpan-fragmentation-test.cc.
References ns3::Packet::Copy(), m_receivedPacketServer, ns3::Socket::RecvFrom(), ns3::Packet::RemoveAllByteTags(), and ns3::Packet::RemoveAllPacketTags().
Referenced by StartServer().
Definition at line 241 of file sixlowpan-fragmentation-test.cc.
References m_data, m_dataSize, m_size, m_socketClient, and ns3::Socket::Send().
Referenced by DoRun().
void SixlowpanFragmentationTest::SetFill | ( | uint8_t * | fill, |
uint32_t | fillSize, | ||
uint32_t | dataSize | ||
) |
Definition at line 214 of file sixlowpan-fragmentation-test.cc.
References m_data, m_dataSize, and m_size.
Referenced by DoRun().
Definition at line 174 of file sixlowpan-fragmentation-test.cc.
References ns3::Socket::Bind(), ns3::Socket::Connect(), HandleReadClient(), HandleReadIcmpClient(), m_socketClient, ns3::MakeCallback(), ns3::ObjectBase::SetAttribute(), and ns3::Socket::SetRecvCallback().
Referenced by DoRun().
Definition at line 141 of file sixlowpan-fragmentation-test.cc.
References ns3::Socket::Bind(), HandleReadServer(), m_socketServer, ns3::MakeCallback(), and ns3::Socket::SetRecvCallback().
Referenced by DoRun().
|
private |
Definition at line 95 of file sixlowpan-fragmentation-test.cc.
Referenced by DoRun(), SendClient(), SetFill(), SixlowpanFragmentationTest(), and ~SixlowpanFragmentationTest().
|
private |
Definition at line 94 of file sixlowpan-fragmentation-test.cc.
Referenced by SendClient(), SetFill(), SixlowpanFragmentationTest(), and ~SixlowpanFragmentationTest().
|
private |
Definition at line 98 of file sixlowpan-fragmentation-test.cc.
Referenced by DoRun(), and HandleReadIcmpClient().
|
private |
Definition at line 97 of file sixlowpan-fragmentation-test.cc.
Referenced by DoRun(), and HandleReadIcmpClient().
Definition at line 88 of file sixlowpan-fragmentation-test.cc.
Referenced by HandleReadClient().
Definition at line 89 of file sixlowpan-fragmentation-test.cc.
Referenced by DoRun(), and HandleReadServer().
Definition at line 87 of file sixlowpan-fragmentation-test.cc.
|
private |
Definition at line 96 of file sixlowpan-fragmentation-test.cc.
Referenced by SendClient(), and SetFill().
Definition at line 93 of file sixlowpan-fragmentation-test.cc.
Referenced by DoRun(), SendClient(), and StartClient().
Definition at line 92 of file sixlowpan-fragmentation-test.cc.
Referenced by SixlowpanFragmentationTest(), and StartServer().