13#include "ns3/string.h"
14#include "ns3/tcp-congestion-ops.h"
15#include "ns3/tcp-prr-recovery.h"
16#include "ns3/tcp-recovery-ops.h"
17#include "ns3/tcp-socket-base.h"
48 const std::string& name);
51 void DoRun()
override;
71 const std::string& name)
100 "There should be at least one transmission on entering recovery");
118 "Updated cwnd should be less than or equal to the existing cwnd");
125 "Updated cwnd should be greater than or equal to the existing cwnd");
148 "Prr test on cWnd when bytesInFlight is greater than ssThresh with SSRB"),
158 "Prr test on cWnd when bytesInFlight is lower than ssThresh with SSRB"),
168 "Prr test on cWnd when bytesInFlight is greater than ssThresh with CRB"),
178 "Prr test on cWnd when bytesInFlight is lower than ssThresh with CRB"),
PRR Recovery algorithm test.
void DoRun() override
Implementation to actually run this TestCase.
uint32_t m_bytesInFlight
Current bytes in flight.
uint32_t m_bytesSent
Bytes sent while in recovery phase.
PrrRecoveryTest(uint32_t cWnd, uint32_t segmentSize, uint32_t ssThresh, uint32_t unAckDataCount, uint32_t bytesInFlight, uint32_t m_deliveredBytes, uint32_t bytesSent, const std::string &name)
Constructor.
uint32_t m_segmentSize
Segment size.
Ptr< TcpSocketState > m_state
TCP socket state.
uint32_t m_ssThresh
Slow Start Threshold.
uint32_t m_deliveredBytes
Bytes SACKed on last acknowledgment.
uint32_t m_cWnd
Congestion window.
uint32_t m_unAckDataCount
Unacknowledged data at the start of recovery.
Smart pointer class similar to boost::intrusive_ptr.
void AddTestCase(TestCase *testCase, Duration duration=Duration::QUICK)
Add an individual child TestCase to this test suite.
TestCase(const TestCase &)=delete
Caller graph was not generated because of its size.
@ UNIT
This test suite implements a Unit Test.
TestSuite(std::string name, Type type=Type::UNIT)
Construct a new test suite.
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
Ptr< T > CreateObject(Args &&... args)
Create an object by type, with varying number of constructor parameters.
#define NS_TEST_ASSERT_MSG_LT_OR_EQ(actual, limit, msg)
Test that an actual value is less than or equal to a limit and report and abort if not.
#define NS_TEST_ASSERT_MSG_GT_OR_EQ(actual, limit, msg)
Test that an actual value is greater than or equal to a limit and report and abort if not.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
static PrrRecoveryTestSuite g_TcpPrrRecoveryTest
Static variable for test initialization.