encapsulates test code More...
#include <test.h>
Inherited by AlternateFindTestCase, BasicAddTestCase, BasicEnergyDepletionTest, BasicEnergyUpdateTest, BasicFindTestCase, BasicRenameTestCase, BasicTracedCallbackTestCase, BatteryLifetimeTest, CsmaBridgeTestCase, CsmaBroadcastTestCase, CsmaMulticastTestCase, CsmaOneSubnetTestCase, CsmaPacketSocketTestCase, CsmaPingTestCase, CsmaRawIpSocketTestCase, CsmaStarTestCase, CtrlBAckResponseHeaderTest, DiffTestCase, DsaRequestTestCase, DynamicGlobalRoutingTestCase, ErrorModelSimple, FileHeaderTestCase, FindPathTestCase, FiveDoublesAverageTestCase, FiveDoublesTestCase, FiveIntegersAverageTestCase, FiveIntegersTestCase, FlameRegressionTest, FriisPropagationLossModelTestCase, FullyQualifiedAddTestCase, FullyQualifiedFindTestCase, FullyQualifiedRenameTestCase, GlobalRoutingSlash32TestCase, HwmpDoRfRegressionTest, HwmpProactiveRegressionTest, HwmpReactiveRegressionTest, HwmpSimplestRegressionTest, IpAddressHelperTestCasev6, Ipv6AddressTestCase1, LogDistancePropagationLossModelTestCase, MatrixPropagationLossModelTestCase, ns3::AcousticModemEnergyDepletionTestCase, ns3::AcousticModemEnergyTestCase, ns3::AddressAllocator6TestCase, ns3::AddressAllocatorHelperTestCase, ns3::AddressAllocatorTestCase, ns3::AddressCollision6TestCase, ns3::AddressCollisionTestCase, ns3::AggregateObjectTestCase, ns3::AnimationInterfaceTestCase, ns3::aodv::AodvRqueueTest, ns3::aodv::AodvRtableEntryTest, ns3::aodv::AodvRtableTest, ns3::aodv::Bug772ChainTest, ns3::aodv::ChainRegressionTest, ns3::aodv::IdCacheTest, ns3::aodv::LoopbackTestCase, ns3::aodv::NeighborTest, ns3::aodv::QueueEntryTest, ns3::aodv::RerrHeaderTest, ns3::aodv::RrepAckHeaderTest, ns3::aodv::RrepHeaderTest, ns3::aodv::RreqHeaderTest, ns3::aodv::TypeHeaderTest, ns3::AttributeTestCase< T >, ns3::BasicCallbackTestCase, ns3::BasicRandomNumberTestCase, ns3::BufferTest, ns3::BuildingsHelperOneTestCase, ns3::BuildingsPathlossTestCase, ns3::BuildingsShadowingTestCase, ns3::CallbackValueTestCase, ns3::CommandLineTestCaseBase, ns3::CosineAntennaModelTestCase, ns3::CreateObjectTestCase, ns3::DcfManagerTest, ns3::DegreesToRadiansTestCase, ns3::dot11s::HwmpRtableTest, ns3::dot11s::MeshHeaderTest, ns3::dot11s::PeerLinkFrameStartTest, ns3::DropTailQueueTestCase, ns3::DsdvHeaderTestCase, ns3::DsdvTableTestCase, ns3::dsr::DsrAckHeaderTest, ns3::dsr::DsrAckReqHeaderTest, ns3::dsr::DsrCacheEntryTest, ns3::dsr::DsrFsHeaderTest, ns3::dsr::DsrRerrHeaderTest, ns3::dsr::DsrRrepHeaderTest, ns3::dsr::DsrRreqHeaderTest, ns3::dsr::DsrRreqTableTest, ns3::dsr::DsrSendBuffTest, ns3::dsr::DsrSRHeaderTest, ns3::DualStackTestCase, ns3::EpcS1uDlTestCase, ns3::EpcS1uUlTestCase, ns3::EpcTftClassifierTestCase, ns3::EpsGtpuHeaderTestCase, ns3::EventGarbageCollectorTestCase, ns3::ExampleAddress6GeneratorTestCase, ns3::ExampleAddressGeneratorTestCase, ns3::flame::FlameHeaderTest, ns3::flame::FlameRtableTest, ns3::GlobalRouteManagerImplTestCase, ns3::GlobalValueTestCase, ns3::HistogramTestCase, ns3::Int64x64ArithmeticTestCase, ns3::Int64x64Bug455TestCase, ns3::Int64x64Bug863TestCase, ns3::Int64x64CompareTestCase, ns3::Int64x64FracTestCase, ns3::Int64x64InputOutputTestCase, ns3::Int64x64InputTestCase, ns3::Int64x64InvertTestCase, ns3::IntegerTraceSourceAttributeTestCase, ns3::IntegerTraceSourceTestCase, ns3::InterferenceHelperSequenceTest, ns3::IpAddressHelperTestCasev4, ns3::Ipv4FragmentationTest, ns3::Ipv4HeaderTest, ns3::Ipv4L3ProtocolTestCase, ns3::Ipv4ListRoutingNegativeTestCase, ns3::Ipv4ListRoutingPositiveTestCase, ns3::Ipv4PacketInfoTagTest, ns3::Ipv4RawSocketImplTest, ns3::Ipv6FragmentationTest, ns3::Ipv6L3ProtocolTestCase, ns3::Ipv6ListRoutingNegativeTestCase, ns3::Ipv6ListRoutingPositiveTestCase, ns3::Ipv6PacketInfoTagTest, ns3::IsotropicAntennaModelTestCase, ns3::ItuR1411LosPropagationLossModelTestCase, ns3::ItuR1411NlosOverRooftopPropagationLossModelTestCase, ns3::Kun2600MhzPropagationLossModelTestCase, ns3::LenaMimoTestCase, ns3::LenaPfFfMacSchedulerTestCase1, ns3::LenaPfFfMacSchedulerTestCase2, ns3::LenaPhyErrorModelTestCase, ns3::LenaRrFfMacSchedulerTestCase, ns3::LiIonEnergyTestCase, ns3::LteDownlinkSinrTestCase, ns3::LteEarfcnTestCase, ns3::LteEnbAntennaTestCase, ns3::LteEpcE2eDataTestCase, ns3::LteFadingSystemTestCase, ns3::LteFadingTestCase, ns3::LteInterferenceTestCase, ns3::LteLinkAdaptationTestCase, ns3::LteNoisePsdTestCase, ns3::LtePathlossModelSystemTestCase, ns3::LteRlcAmE2eTestCase, ns3::LteRlcAmTransmitterTestCase, ns3::LteRlcUmE2eTestCase, ns3::LteRlcUmTransmitterTestCase, ns3::LteSpectrumModelTestCase, ns3::LteTxPsdTestCase, ns3::LteUplinkSinrTestCase, ns3::MakeBoundCallbackTestCase, ns3::MakeCallbackTemplatesTestCase, ns3::MakeCallbackTestCase, ns3::MeshInformationElementVectorBist, ns3::NetworkAllocatorHelperTestCase, ns3::NetworkAndAddress6TestCase, ns3::NetworkAndAddressTestCase, ns3::NetworkNumber6AllocatorTestCase, ns3::NetworkNumberAllocatorTestCase, ns3::Ns2MobilityHelperTest, ns3::NullifyCallbackTestCase, ns3::ObjectFactoryTestCase, ns3::ObjectMapAttributeTestCase, ns3::ObjectVectorAttributeTestCase, ns3::ObjectVectorConfigTestCase, ns3::ObjectVectorTraceConfigTestCase, ns3::OkumuraHataPropagationLossModelTestCase, ns3::olsr::Bug780Test, ns3::olsr::HelloRegressionTest, ns3::olsr::OlsrMprTestCase, ns3::olsr::TcRegressionTest, ns3::OlsrEmfTestCase, ns3::OlsrHelloTestCase, ns3::OlsrHnaTestCase, ns3::OlsrMidTestCase, ns3::OlsrTcTestCase, ns3::OneVectorConstructorTestCase, ns3::PacketMetadataTest, ns3::PacketTest, ns3::ParabolicAntennaModelTestCase, ns3::PointerAttributeTestCase, ns3::PointToPointTest, ns3::PtrTestCase, ns3::QosUtilsIsOldPacketTest, ns3::RadiansToDegreesTestCase, ns3::RandomNumberSerializationTestCase, ns3::RandomRoomPositionAllocatorTestCase, ns3::RandomVariableStreamAttributeTestCase, ns3::RedQueueTestCase, ns3::ResetAllocatorHelperTestCase, ns3::RocketfuelTopologyReaderTest, ns3::RootNamespaceConfigTestCase, ns3::SameRoomPositionAllocatorTestCase, ns3::SequenceNumberTestCase, ns3::SimulatorEventsTestCase, ns3::SimulatorTemplateTestCase, ns3::SpectrumIdealPhyTestCase, ns3::SpectrumInterferenceTestCase, ns3::SpectrumValueTestCase, ns3::SteadyStateRandomWaypointTest, ns3::TcpTestCase, ns3::TestSuite, ns3::ThreadedSimulatorEventsTestCase, ns3::TimerStateTestCase, ns3::TimerTemplateTestCase, ns3::TimeSimpleTestCase, ns3::TimesWithSignsTestCase, ns3::TracedCallbackTestCase, ns3::TwoVectorsConstructorTestCase, ns3::TxDurationTest, ns3::TypeTraitsTestCase, ns3::Udp6SocketImplTest, ns3::Udp6SocketLoopbackTest, ns3::UdpSocketImplTest, ns3::UdpSocketLoopbackTest, ns3::UnderRootNamespaceConfigTestCase, ns3::WatchdogTestCase, ns3::WaypointMobilityModelNotifyTest, ns3::WifiTest, Ns3TcpCwndTestCase1, Ns3TcpCwndTestCase2, Ns3TcpInteroperabilityTestCase, Ns3TcpLossTestCase, Ns3TcpNoDelayTestCase, Ns3TcpSocketTestCase1, Ns3TcpSocketTestCase2, Ns3TcpStateTestCase, Ns3WimaxCsParamTlvTestCase, Ns3WimaxFragmentationTestCase, Ns3WimaxManagementConnectionsTestCase, Ns3WimaxNetworkEntryTestCase, Ns3WimaxSchedulingTestCase, Ns3WimaxSfCreationTestCase, Ns3WimaxSfTlvTestCase, Ns3WimaxSFTypeTestCase, Ns3WimaxSimpleOFDMTestCase, Ns3WimaxSNRtoBLERTestCase, NscTcpLossTestCase1, NscTcpLossTestCase2, OneIntegerAverageTestCase, OneIntegerTestCase, PacketBufferingCaseA, PacketBufferingCaseB, PacketLossCounterTestCase, PbbTestCase, PeerManagementProtocolRegressionTest, RandomVariableStreamConstantTestCase, RandomVariableStreamDeterministicTestCase, RandomVariableStreamEmpiricalAntitheticTestCase, RandomVariableStreamEmpiricalTestCase, RandomVariableStreamErlangAntitheticTestCase, RandomVariableStreamErlangTestCase, RandomVariableStreamExponentialAntitheticTestCase, RandomVariableStreamExponentialTestCase, RandomVariableStreamGammaAntitheticTestCase, RandomVariableStreamGammaTestCase, RandomVariableStreamLogNormalAntitheticTestCase, RandomVariableStreamLogNormalTestCase, RandomVariableStreamNormalAntitheticTestCase, RandomVariableStreamNormalTestCase, RandomVariableStreamParetoAntitheticTestCase, RandomVariableStreamParetoTestCase, RandomVariableStreamSequentialTestCase, RandomVariableStreamUniformAntitheticTestCase, RandomVariableStreamUniformTestCase, RandomVariableStreamWeibullAntitheticTestCase, RandomVariableStreamWeibullTestCase, RandomVariableStreamZetaAntitheticTestCase, RandomVariableStreamZetaTestCase, RandomVariableStreamZipfAntitheticTestCase, RandomVariableStreamZipfTestCase, RangePropagationLossModelTestCase, ReadFileTestCase, ReadModeCreateTestCase, RecordHeaderTestCase, RelativeAddTestCase, RelativeFindTestCase, RelativeRenameTestCase, RngExponentialTestCase, RngNormalTestCase, RngParetoTestCase, RngUniformTestCase, SampleTestCase1, StaticRoutingSlash32TestCase, StringContextAddTestCase, StringContextFindTestCase, StringContextRenameTestCase, SwitchFlowTableTestCase, TestEmptyOptionField, TestFulfilledAlignment, TestOptionWithAlignment, TestOptionWithoutAlignment, TwoRayGroundPropagationLossModelTestCase, UanTest, UdpClientServerTestCase, UdpEchoClientSetFillTestCase, UdpTraceClientServerTestCase, WaypointInitialPositionIsWaypoint, WaypointLazyNotifyFalse, WaypointLazyNotifyTrue, WaypointMobilityModelViaHelper, WifiInterferenceTestCase, WifiMsduAggregatorThroughputTest, and WriteModeCreateTestCase.
Classes | |
struct | Result |
Public Member Functions | |
virtual | ~TestCase () |
Protected Member Functions | |
TestCase (std::string name) | |
void | AddTestCase (TestCase *testCase) |
Add an individual test case to this test suite. | |
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) |
Private Member Functions | |
TestCase (TestCase &tc) | |
virtual void | DoRun (void)=0 |
Implementation to actually run this test case. | |
virtual void | DoSetup (void) |
Implementation to do any local setup required for this test case. | |
virtual void | DoTeardown (void) |
Implementation to do any local setup required for this test case. | |
bool | IsFailed (void) const |
TestCase & | operator= (TestCase &tc) |
void | Run (TestRunnerImpl *runner) |
Private Attributes | |
std::vector< TestCase * > | m_children |
std::string | m_dataDir |
std::string | m_name |
TestCase * | m_parent |
struct Result * | m_result |
TestRunnerImpl * | m_runner |
Friends | |
class | TestRunnerImpl |
encapsulates test code
To allow a new test to be run within the ns-3 test framework, users need to create subclasses of this base class, override the DoRun method, and use the NS_TEST_* macros within DoRun.
|
virtual |
|
protected |
|
private |
|
protected |
Add an individual test case to this test suite.
testCase | Pointer to the test case object to be added. |
Definition at line 157 of file test.cc.
References m_children, m_name, m_parent, and NS_FATAL_ERROR.
Referenced by ns3::AnglesTestSuite::AnglesTestSuite(), ns3::AnimationInterfaceTestSuite::AnimationInterfaceTestSuite(), ns3::aodv::AodvRegressionTestSuite::AodvRegressionTestSuite(), ns3::aodv::AodvTestSuite::AodvTestSuite(), ns3::AttributesTestSuite::AttributesTestSuite(), AverageTestSuite::AverageTestSuite(), BasicDataCalculatorsTestSuite::BasicDataCalculatorsTestSuite(), BasicEnergyModelTestSuite::BasicEnergyModelTestSuite(), ns3::BasicRandomNumberTestSuite::BasicRandomNumberTestSuite(), BlockAckTestSuite::BlockAckTestSuite(), ns3::BufferTestSuite::BufferTestSuite(), ns3::BuildingPositionAllocatorTestSuite::BuildingPositionAllocatorTestSuite(), ns3::BuildingsHelperTestSuite::BuildingsHelperTestSuite(), ns3::BuildingsPathlossTestSuite::BuildingsPathlossTestSuite(), ns3::BuildingsShadowingTestSuite::BuildingsShadowingTestSuite(), ns3::CallbackTestSuite::CallbackTestSuite(), ns3::CommandLineTestSuite::CommandLineTestSuite(), ns3::ConfigTestSuite::ConfigTestSuite(), ns3::CosineAntennaModelTestSuite::CosineAntennaModelTestSuite(), CsmaSystemTestSuite::CsmaSystemTestSuite(), ns3::DcfTestSuite::DcfTestSuite(), ns3::DegreesRadiansTestSuite::DegreesRadiansTestSuite(), ns3::dot11s::Dot11sTestSuite::Dot11sTestSuite(), ns3::DropTailQueueTestSuite::DropTailQueueTestSuite(), ns3::DsdvTestSuite::DsdvTestSuite(), ns3::dsr::DsrTestSuite::DsrTestSuite(), ns3::EpcS1uDlTestSuite::EpcS1uDlTestSuite(), ns3::EpcS1uUlTestSuite::EpcS1uUlTestSuite(), ns3::EpcTftClassifierTestSuite::EpcTftClassifierTestSuite(), ns3::EpsGtpuTestSuite::EpsGtpuTestSuite(), ErrorModelTestSuite::ErrorModelTestSuite(), ns3::EventGarbageCollectorTestSuite::EventGarbageCollectorTestSuite(), ns3::flame::FlameTestSuite::FlameTestSuite(), ns3::GlobalRouteManagerImplTestSuite::GlobalRouteManagerImplTestSuite(), GlobalRoutingTestSuite::GlobalRoutingTestSuite(), ns3::GlobalValueTestSuite::GlobalValueTestSuite(), ns3::HistogramTestSuite::HistogramTestSuite(), ns3::aodv::IdCacheTestSuite::IdCacheTestSuite(), ns3::Int64x64128TestSuite::Int64x64128TestSuite(), ns3::Ipv4AddressGeneratorTestSuite::Ipv4AddressGeneratorTestSuite(), ns3::Ipv4AddressHelperTestSuite::Ipv4AddressHelperTestSuite(), ns3::Ipv4FragmentationTestSuite::Ipv4FragmentationTestSuite(), ns3::Ipv4HeaderTestSuite::Ipv4HeaderTestSuite(), ns3::IPv4L3ProtocolTestSuite::IPv4L3ProtocolTestSuite(), ns3::Ipv4ListRoutingTestSuite::Ipv4ListRoutingTestSuite(), ns3::Ipv4PacketInfoTagTestSuite::Ipv4PacketInfoTagTestSuite(), ns3::Ipv4RawTestSuite::Ipv4RawTestSuite(), ns3::Ipv6AddressGeneratorTestSuite::Ipv6AddressGeneratorTestSuite(), Ipv6AddressHelperTestSuite::Ipv6AddressHelperTestSuite(), Ipv6AddressTestSuite::Ipv6AddressTestSuite(), ns3::Ipv6DualStackTestSuite::Ipv6DualStackTestSuite(), ns3::Ipv6FragmentationTestSuite::Ipv6FragmentationTestSuite(), ns3::IPv6L3ProtocolTestSuite::IPv6L3ProtocolTestSuite(), ns3::Ipv6ListRoutingTestSuite::Ipv6ListRoutingTestSuite(), ns3::Ipv6PacketInfoTagTestSuite::Ipv6PacketInfoTagTestSuite(), ns3::IsotropicAntennaModelTestSuite::IsotropicAntennaModelTestSuite(), ns3::ItuR1411LosPropagationLossModelTestSuite::ItuR1411LosPropagationLossModelTestSuite(), ns3::ItuR1411NlosOverRooftopPropagationLossModelTestSuite::ItuR1411NlosOverRooftopPropagationLossModelTestSuite(), ns3::Kun2600MhzPropagationLossModelTestSuite::Kun2600MhzPropagationLossModelTestSuite(), ns3::LenaTestMimoSuite::LenaTestMimoSuite(), ns3::LenaTestPfFfMacSchedulerSuite::LenaTestPfFfMacSchedulerSuite(), ns3::LenaTestPhyErrorModelrSuite::LenaTestPhyErrorModelrSuite(), ns3::LenaTestRrFfMacSchedulerSuite::LenaTestRrFfMacSchedulerSuite(), ns3::LiIonEnergySourceTestSuite::LiIonEnergySourceTestSuite(), ns3::LteAntennaTestSuite::LteAntennaTestSuite(), ns3::LteDownlinkSinrTestSuite::LteDownlinkSinrTestSuite(), ns3::LteEarfcnTestSuite::LteEarfcnTestSuite(), ns3::LteEpcE2eDataTestSuite::LteEpcE2eDataTestSuite(), ns3::LteFadingTestSuite::LteFadingTestSuite(), ns3::LteInterferenceTestSuite::LteInterferenceTestSuite(), ns3::LteLinkAdaptationTestSuite::LteLinkAdaptationTestSuite(), ns3::LtePathlossModelTestSuite::LtePathlossModelTestSuite(), ns3::LteRlcAmE2eTestSuite::LteRlcAmE2eTestSuite(), ns3::LteRlcAmTransmitterTestSuite::LteRlcAmTransmitterTestSuite(), ns3::LteRlcUmE2eTestSuite::LteRlcUmE2eTestSuite(), ns3::LteRlcUmTransmitterTestSuite::LteRlcUmTransmitterTestSuite(), ns3::LteSpectrumValueHelperTestSuite::LteSpectrumValueHelperTestSuite(), ns3::LteUplinkSinrTestSuite::LteUplinkSinrTestSuite(), ns3::MeshTestSuite::MeshTestSuite(), MobilityTestSuite::MobilityTestSuite(), NamesTestSuite::NamesTestSuite(), ns3::Ns2MobilityHelperTestSuite::Ns2MobilityHelperTestSuite(), Ns3TcpCwndTestSuite::Ns3TcpCwndTestSuite(), Ns3TcpInteroperabilityTestSuite::Ns3TcpInteroperabilityTestSuite(), Ns3TcpLossTestSuite::Ns3TcpLossTestSuite(), Ns3TcpNoDelayTestSuite::Ns3TcpNoDelayTestSuite(), Ns3TcpSocketTestSuite::Ns3TcpSocketTestSuite(), Ns3TcpStateTestSuite::Ns3TcpStateTestSuite(), Ns3WimaxFragmentationTestSuite::Ns3WimaxFragmentationTestSuite(), Ns3WimaxMacMessagesTestSuite::Ns3WimaxMacMessagesTestSuite(), Ns3WimaxPhyTestSuite::Ns3WimaxPhyTestSuite(), Ns3WimaxQoSTestSuite::Ns3WimaxQoSTestSuite(), Ns3WimaxServiceFlowTestSuite::Ns3WimaxServiceFlowTestSuite(), Ns3WimaxSSMacTestSuite::Ns3WimaxSSMacTestSuite(), Ns3WimaxTlvTestSuite::Ns3WimaxTlvTestSuite(), NscTcpLossTestSuite::NscTcpLossTestSuite(), ns3::ObjectTestSuite::ObjectTestSuite(), ns3::OkumuraHataPropagationLossModelTestSuite::OkumuraHataPropagationLossModelTestSuite(), ns3::olsr::OlsrProtocolTestSuite::OlsrProtocolTestSuite(), ns3::OlsrTestSuite::OlsrTestSuite(), ns3::PacketMetadataTestSuite::PacketMetadataTestSuite(), ns3::PacketTestSuite::PacketTestSuite(), ns3::ParabolicAntennaModelTestSuite::ParabolicAntennaModelTestSuite(), PbbTestSuite::PbbTestSuite(), PcapFileTestSuite::PcapFileTestSuite(), ns3::PointToPointTestSuite::PointToPointTestSuite(), PropagationLossModelsTestSuite::PropagationLossModelsTestSuite(), ns3::PtrTestSuite::PtrTestSuite(), RandomVariableStreamTestSuite::RandomVariableStreamTestSuite(), ns3::RedQueueTestSuite::RedQueueTestSuite(), ns3::olsr::RegressionTestSuite::RegressionTestSuite(), RngTestSuite::RngTestSuite(), ns3::RocketfuelTopologyReaderTestSuite::RocketfuelTopologyReaderTestSuite(), RvBatteryModelTestSuite::RvBatteryModelTestSuite(), SampleTestSuite::SampleTestSuite(), ns3::SequenceNumberTestSuite::SequenceNumberTestSuite(), ns3::SimulatorTestSuite::SimulatorTestSuite(), ns3::SpectrumConverterTestSuite::SpectrumConverterTestSuite(), ns3::SpectrumIdealPhyTestSuite::SpectrumIdealPhyTestSuite(), ns3::SpectrumInterferenceTestSuite::SpectrumInterferenceTestSuite(), ns3::SpectrumValueTestSuite::SpectrumValueTestSuite(), StaticRoutingTestSuite::StaticRoutingTestSuite(), ns3::SteadyStateRandomWaypointTestSuite::SteadyStateRandomWaypointTestSuite(), SwitchTestSuite::SwitchTestSuite(), ns3::TcpTestSuite::TcpTestSuite(), ns3::ThreadedSimulatorTestSuite::ThreadedSimulatorTestSuite(), ns3::TimerTestSuite::TimerTestSuite(), ns3::TimeTestSuite::TimeTestSuite(), TracedCallbackTestSuite::TracedCallbackTestSuite(), ns3::TxDurationTestSuite::TxDurationTestSuite(), ns3::TypeTraitsTestSuite::TypeTraitsTestSuite(), ns3::UanEnergyModelTestSuite::UanEnergyModelTestSuite(), UanTestSuite::UanTestSuite(), UdpClientServerTestSuite::UdpClientServerTestSuite(), ns3::UdpTestSuite::UdpTestSuite(), ns3::WatchdogTestSuite::WatchdogTestSuite(), ns3::WaypointMobilityModelTestSuite::WaypointMobilityModelTestSuite(), WifiInterferenceTestSuite::WifiInterferenceTestSuite(), WifiMsduAggregatorTestSuite::WifiMsduAggregatorTestSuite(), and ns3::WifiTestSuite::WifiTestSuite().
|
protected |
Definition at line 246 of file test.cc.
References ns3::SystemPath::Append(), ns3::TestRunnerImpl::GetTopLevelSourceDir(), m_dataDir, m_parent, m_runner, and NS_FATAL_ERROR.
Referenced by CreateTempDirFilename(), ReadFileTestCase::DoRun(), DiffTestCase::DoRun(), and Ns3TcpLossTestCase::DoSetup().
|
protected |
Definition at line 263 of file test.cc.
References ns3::SystemPath::Append(), CreateDataDirFilename(), ns3::TestRunnerImpl::GetTempDir(), ns3::SystemPath::Join(), m_name, m_parent, m_runner, ns3::SystemPath::MakeDirectories(), and ns3::TestRunnerImpl::MustUpdateData().
Referenced by PeerManagementProtocolRegressionTest::CreateDevices(), ns3::aodv::Bug772ChainTest::CreateDevices(), FlameRegressionTest::CreateDevices(), HwmpProactiveRegressionTest::CreateDevices(), HwmpDoRfRegressionTest::CreateDevices(), HwmpSimplestRegressionTest::CreateDevices(), HwmpReactiveRegressionTest::CreateDevices(), ns3::aodv::ChainRegressionTest::CreateDevices(), ns3::olsr::Bug780Test::CreateNodes(), ns3::olsr::HelloRegressionTest::CreateNodes(), ns3::olsr::TcRegressionTest::CreateNodes(), WriteModeCreateTestCase::DoSetup(), ReadModeCreateTestCase::DoSetup(), FileHeaderTestCase::DoSetup(), RecordHeaderTestCase::DoSetup(), and ns3::Ns2MobilityHelperTest::WriteTrace().
|
privatepure virtual |
Implementation to actually run this test case.
Subclasses should override this method to conduct their tests.
Implemented in ns3::dsr::DsrRreqTableTest, ns3::aodv::AodvRtableTest, ns3::aodv::AodvRtableEntryTest, ns3::Udp6SocketImplTest, ns3::dsr::DsrSendBuffTest, ns3::dsr::DsrCacheEntryTest, ns3::dsr::DsrAckHeaderTest, ns3::aodv::AodvRqueueTest, ns3::aodv::QueueEntryTest, ns3::dsr::DsrAckReqHeaderTest, ns3::Int64x64InvertTestCase, ns3::PacketMetadataTest, ns3::OlsrHnaTestCase, ns3::Int64x64CompareTestCase, ns3::aodv::RerrHeaderTest, ns3::dsr::DsrRerrHeaderTest, ns3::OlsrTcTestCase, ns3::aodv::RrepAckHeaderTest, ns3::dot11s::PeerLinkFrameStartTest, ns3::Int64x64Bug863TestCase, ns3::PacketTest, ns3::AcousticModemEnergyDepletionTestCase, ns3::UdpSocketImplTest, TestFulfilledAlignment, ns3::InterferenceHelperSequenceTest, ns3::dsr::DsrSRHeaderTest, ns3::Int64x64Bug455TestCase, ns3::aodv::RrepHeaderTest, ns3::QosUtilsIsOldPacketTest, ns3::OlsrHelloTestCase, ns3::Udp6SocketLoopbackTest, TestOptionWithAlignment, ns3::dsr::DsrRrepHeaderTest, ns3::NetworkAndAddressTestCase, ns3::aodv::RreqHeaderTest, ns3::NetworkAndAddress6TestCase, ns3::Int64x64ArithmeticTestCase, ns3::ResetAllocatorHelperTestCase, ns3::UdpSocketLoopbackTest, ns3::Ipv6FragmentationTest, ns3::DsdvTableTestCase, ns3::aodv::TypeHeaderTest, ns3::TimerTemplateTestCase, ns3::dsr::DsrRreqHeaderTest, ns3::Ipv4FragmentationTest, ns3::Ipv6ListRoutingPositiveTestCase, ns3::dot11s::HwmpRtableTest, TestOptionWithoutAlignment, ns3::Ipv4ListRoutingPositiveTestCase, ns3::Ipv4RawSocketImplTest, ns3::Int64x64InputOutputTestCase, ns3::Ipv4HeaderTest, HwmpReactiveRegressionTest, ns3::SequenceNumberTestCase, HwmpSimplestRegressionTest, HwmpDoRfRegressionTest, ns3::Ipv6ListRoutingNegativeTestCase, ns3::dsr::DsrFsHeaderTest, HwmpProactiveRegressionTest, ns3::flame::FlameRtableTest, FlameRegressionTest, ns3::DcfManagerTest, ns3::Ipv4ListRoutingNegativeTestCase, ns3::DsdvHeaderTestCase, ns3::TimerStateTestCase, ns3::Ipv6L3ProtocolTestCase, ns3::OlsrMidTestCase, ns3::Ipv4L3ProtocolTestCase, ns3::LteRlcAmTransmitterTestCase, ns3::LteRlcUmTransmitterTestCase, ns3::AcousticModemEnergyTestCase, WifiMsduAggregatorThroughputTest, ns3::AnimationInterfaceTestCase, ns3::olsr::OlsrMprTestCase, ns3::WifiTest, ns3::MeshInformationElementVectorBist, ns3::aodv::IdCacheTest, ns3::Int64x64InputTestCase, ns3::SpectrumInterferenceTestCase, ns3::SpectrumValueTestCase, TestEmptyOptionField, UanTest, PbbTestCase, ns3::aodv::LoopbackTestCase, ns3::dot11s::MeshHeaderTest, ns3::LiIonEnergyTestCase, ns3::GlobalRouteManagerImplTestCase, ns3::flame::FlameHeaderTest, ns3::EventGarbageCollectorTestCase, ns3::TxDurationTest, ns3::aodv::NeighborTest, ns3::RedQueueTestCase, ns3::SimulatorEventsTestCase, ns3::HistogramTestCase, ns3::NetworkNumber6AllocatorTestCase, ns3::OlsrEmfTestCase, ns3::WatchdogTestCase, ns3::NetworkNumberAllocatorTestCase, ns3::DropTailQueueTestCase, ns3::BufferTest, ns3::PointToPointTest, and ns3::Int64x64FracTestCase.
Referenced by Run().
|
privatevirtual |
|
privatevirtual |
Implementation to do any local setup required for this test case.
Subclasses should override this method to perform any costly per-test teardown
Reimplemented in ns3::NetworkAndAddressTestCase, ns3::NetworkAndAddress6TestCase, ns3::ResetAllocatorHelperTestCase, ns3::TimerTemplateTestCase, ns3::NetworkNumber6AllocatorTestCase, and ns3::NetworkNumberAllocatorTestCase.
Definition at line 309 of file test.cc.
Referenced by Run().
|
protected |
This method is deprecated. IsStatusFailure replaces it.
Definition at line 284 of file test.cc.
References IsStatusFailure().
|
protected |
Definition at line 214 of file test.cc.
References m_name.
Referenced by ns3::LteFadingTestCase::DoRun(), ns3::TestRunnerImpl::FilterTests(), ns3::TestRunnerImpl::PrintReport(), and ns3::TestRunnerImpl::PrintTestNameList().
|
private |
Definition at line 186 of file test.cc.
References ns3::TestCase::Result::childrenFailed, ns3::TestCase::Result::failure, and m_result.
Referenced by ns3::TestRunnerImpl::PrintReport(), ns3::TestRunnerImpl::Run(), and Run().
|
protected |
Definition at line 289 of file test.cc.
References IsStatusSuccess().
Referenced by ns3::Ns2MobilityHelperTest::CheckInitialPositions(), and GetErrorStatus().
|
protected |
Definition at line 294 of file test.cc.
References ns3::TestCase::Result::failure, and m_result.
Referenced by Ns3TcpStateTestCase::Ipv4L3Tx(), Ns3TcpLossTestCase::Ipv4L3Tx(), Ns3TcpInteroperabilityTestCase::Ipv4L3Tx(), and IsStatusFailure().
|
protected |
Definition at line 235 of file test.cc.
References m_runner, and ns3::TestRunnerImpl::MustAssertOnFailure().
|
protected |
Definition at line 240 of file test.cc.
References m_runner, and ns3::TestRunnerImpl::MustContinueOnFailure().
|
protected |
Definition at line 219 of file test.cc.
References ns3::TestCase::Result::childrenFailed, ns3::TestCase::Result::failure, m_parent, and m_result.
|
private |
Definition at line 192 of file test.cc.
References ns3::TestCase::Result::clock, DoRun(), DoSetup(), DoTeardown(), ns3::SystemWallClockMs::End(), IsFailed(), m_children, m_result, m_runner, Run(), ns3::SystemWallClockMs::Start(), and test().
Referenced by BatteryLifetimeTest::ConstantLoadTest(), BasicEnergyDepletionTest::DepletionTestCase(), UanTest::DoOnePhyTest(), ns3::PointToPointTest::DoRun(), ns3::WatchdogTestCase::DoRun(), ns3::SimulatorEventsTestCase::DoRun(), ns3::aodv::NeighborTest::DoRun(), ns3::GlobalRouteManagerImplTestCase::DoRun(), ns3::EventGarbageCollectorTestCase::DoRun(), ns3::LiIonEnergyTestCase::DoRun(), ns3::aodv::LoopbackTestCase::DoRun(), ns3::LenaMimoTestCase::DoRun(), ns3::SteadyStateRandomWaypointTest::DoRun(), ns3::SpectrumInterferenceTestCase::DoRun(), ns3::aodv::IdCacheTest::DoRun(), ns3::olsr::Bug780Test::DoRun(), ns3::LenaPhyErrorModelTestCase::DoRun(), ns3::LenaRrFfMacSchedulerTestCase::DoRun(), WaypointLazyNotifyFalse::DoRun(), ns3::LteRlcAmE2eTestCase::DoRun(), ns3::LteRlcUmE2eTestCase::DoRun(), ns3::WaypointMobilityModelNotifyTest::DoRun(), ns3::AnimationInterfaceTestCase::DoRun(), ns3::LteDownlinkSinrTestCase::DoRun(), ErrorModelSimple::DoRun(), ns3::LenaPfFfMacSchedulerTestCase1::DoRun(), ns3::LteUplinkSinrTestCase::DoRun(), WifiMsduAggregatorThroughputTest::DoRun(), ns3::LteLinkAdaptationTestCase::DoRun(), StaticRoutingSlash32TestCase::DoRun(), ns3::AcousticModemEnergyTestCase::DoRun(), UdpClientServerTestCase::DoRun(), ns3::LteEnbAntennaTestCase::DoRun(), ns3::LteInterferenceTestCase::DoRun(), Ns3TcpNoDelayTestCase::DoRun(), ns3::LteFadingTestCase::DoRun(), Ns3TcpSocketTestCase1::DoRun(), Ns3WimaxSfCreationTestCase::DoRun(), ns3::LtePathlossModelSystemTestCase::DoRun(), Ns3WimaxNetworkEntryTestCase::DoRun(), DynamicGlobalRoutingTestCase::DoRun(), NscTcpLossTestCase1::DoRun(), PeerManagementProtocolRegressionTest::DoRun(), ns3::DualStackTestCase::DoRun(), CsmaBridgeTestCase::DoRun(), FlameRegressionTest::DoRun(), HwmpProactiveRegressionTest::DoRun(), ns3::flame::FlameRtableTest::DoRun(), ns3::ThreadedSimulatorEventsTestCase::DoRun(), ns3::olsr::HelloRegressionTest::DoRun(), Ns3TcpLossTestCase::DoRun(), ns3::TcpTestCase::DoRun(), ns3::LenaPfFfMacSchedulerTestCase2::DoRun(), Ns3TcpStateTestCase::DoRun(), HwmpDoRfRegressionTest::DoRun(), ns3::aodv::Bug772ChainTest::DoRun(), HwmpSimplestRegressionTest::DoRun(), ns3::LteRlcAmTransmitterOneSduTestCase::DoRun(), ns3::LteRlcUmTransmitterOneSduTestCase::DoRun(), ns3::Ipv6PacketInfoTagTest::DoRun(), HwmpReactiveRegressionTest::DoRun(), ns3::EpcS1uDlTestCase::DoRun(), ns3::Ipv4PacketInfoTagTest::DoRun(), ns3::SpectrumIdealPhyTestCase::DoRun(), Ns3TcpInteroperabilityTestCase::DoRun(), ns3::LteRlcAmTransmitterSegmentationTestCase::DoRun(), ns3::LteRlcUmTransmitterSegmentationTestCase::DoRun(), ns3::dot11s::HwmpRtableTest::DoRun(), ns3::olsr::TcRegressionTest::DoRun(), ns3::LteEpcE2eDataTestCase::DoRun(), ns3::Ipv4FragmentationTest::DoRun(), ns3::TimerTemplateTestCase::DoRun(), ns3::LteRlcAmTransmitterConcatenationTestCase::DoRun(), ns3::LteRlcUmTransmitterConcatenationTestCase::DoRun(), WaypointLazyNotifyTrue::DoRun(), ns3::Ipv6FragmentationTest::DoRun(), ns3::UdpSocketLoopbackTest::DoRun(), Ns3WimaxManagementConnectionsTestCase::DoRun(), ns3::LteRlcAmTransmitterReportBufferStatusTestCase::DoRun(), ns3::LteRlcUmTransmitterReportBufferStatusTestCase::DoRun(), UdpTraceClientServerTestCase::DoRun(), ns3::Udp6SocketLoopbackTest::DoRun(), Ns3TcpSocketTestCase2::DoRun(), WaypointInitialPositionIsWaypoint::DoRun(), CsmaBroadcastTestCase::DoRun(), NscTcpLossTestCase2::DoRun(), ns3::SimulatorTemplateTestCase::DoRun(), Ns3TcpCwndTestCase1::DoRun(), ns3::InterferenceHelperSequenceTest::DoRun(), ns3::aodv::ChainRegressionTest::DoRun(), ns3::AcousticModemEnergyDepletionTestCase::DoRun(), ns3::Ns2MobilityHelperTest::DoRun(), UdpEchoClientSetFillTestCase::DoRun(), ns3::EpcS1uUlTestCase::DoRun(), CsmaMulticastTestCase::DoRun(), WaypointMobilityModelViaHelper::DoRun(), GlobalRoutingSlash32TestCase::DoRun(), ns3::aodv::AodvRqueueTest::DoRun(), Ns3TcpCwndTestCase2::DoRun(), ns3::dsr::DsrSendBuffTest::DoRun(), CsmaOneSubnetTestCase::DoRun(), CsmaPacketSocketTestCase::DoRun(), CsmaPingTestCase::DoRun(), CsmaRawIpSocketTestCase::DoRun(), CsmaStarTestCase::DoRun(), Ns3WimaxSchedulingTestCase::DoRunOnce(), Ns3WimaxSimpleOFDMTestCase::DoRunOnce(), Ns3WimaxSFTypeTestCase::DoRunOnce(), ns3::TimerTemplateTestCase::DoTeardown(), ns3::DcfManagerTest::EndTest(), ns3::TestRunnerImpl::Run(), Run(), ns3::WifiTest::RunOne(), ns3::Ipv4RawSocketImplTest::SendData(), ns3::UdpSocketImplTest::SendData(), ns3::Udp6SocketImplTest::SendData(), ns3::Ipv4RawSocketImplTest::SendData_IpHdr(), ns3::Ipv4HeaderTest::SendData_IpHdr_Dscp(), BasicEnergyUpdateTest::StateSwitchTest(), BatteryLifetimeTest::VariableLoadTest(), and WifiInterferenceTestCase::WifiSimpleInterference().
|
protected |
directory | the directory where the test data is located |
In general, this method is invoked as SetDataDir (NS_TEST_SOURCEDIR); However, if a module contains a test directory with subdirectories (e.g. src/mesh/test), and the test data (e.g. pcap traces) is located in one of these subdirectories, then the variable NS_TEST_SOURCEDIR may not work and the user may want to explicitly pass in a directory string.
Note that NS_TEST_SOURCEDIR is set in src/wscript for each module
Definition at line 300 of file test.cc.
References m_dataDir.
Referenced by ns3::aodv::AodvRegressionTestSuite::AodvRegressionTestSuite(), ns3::Ns2MobilityHelperTestSuite::Ns2MobilityHelperTestSuite(), Ns3TcpLossTestSuite::Ns3TcpLossTestSuite(), PcapFileTestSuite::PcapFileTestSuite(), and ns3::olsr::RegressionTestSuite::RegressionTestSuite().
|
friend |
|
private |
Definition at line 930 of file test.h.
Referenced by AddTestCase(), ns3::TestRunnerImpl::PrintReport(), Run(), and ~TestCase().
|
private |
Definition at line 931 of file test.h.
Referenced by CreateDataDirFilename(), and SetDataDir().
|
private |
Definition at line 934 of file test.h.
Referenced by AddTestCase(), CreateTempDirFilename(), GetName(), and ns3::TestRunnerImpl::PrintReport().
|
private |
Definition at line 927 of file test.h.
Referenced by AddTestCase(), CreateDataDirFilename(), CreateTempDirFilename(), ReportTestFailure(), and ~TestCase().
|
private |
Definition at line 933 of file test.h.
Referenced by IsFailed(), IsStatusSuccess(), ns3::TestRunnerImpl::PrintReport(), ReportTestFailure(), Run(), and ~TestCase().
|
private |
Definition at line 932 of file test.h.
Referenced by CreateDataDirFilename(), CreateTempDirFilename(), MustAssertOnFailure(), MustContinueOnFailure(), Run(), and ~TestCase().