Testing TcpIllinois C-AIMD algorithm. More...
Public Member Functions | |
TcpIllinoisTest (uint32_t cWnd, uint32_t ssThresh, uint32_t segmentSize, uint32_t cntRtt, Time maxRtt, uint32_t segmentsAcked, SequenceNumber32 nextTxSeq, SequenceNumber32 lastAckedSeq, const std::string &name) | |
![]() | |
virtual | ~TestCase () |
Destructor. More... | |
std::string | GetName (void) const |
Private Member Functions | |
void | CalculateAlpha (Ptr< TcpIllinois > cong, double da, double dm) |
Time | CalculateAvgDelay () |
void | CalculateBeta (Ptr< TcpIllinois > cong, double da, double dm) |
Time | CalculateMaxDelay () |
virtual void | DoRun () |
Implementation to actually run this TestCase. More... | |
void | GetSsThresh () |
void | IncreaseWindow (Ptr< TcpIllinois > cong) |
void | RecalcParam (Ptr< TcpIllinois > cong) |
Private Attributes | |
uint32_t | m_ackCnt |
double | m_alpha |
Time | m_baseRtt |
double | m_beta |
uint32_t | m_cntRtt |
uint32_t | m_cWnd |
SequenceNumber32 | m_lastAckedSeq |
Time | m_maxRtt |
SequenceNumber32 | m_nextTxSeq |
bool | m_rttAbove |
uint8_t | m_rttLow |
uint32_t | m_segmentsAcked |
uint32_t | m_segmentSize |
uint32_t | m_ssThresh |
Time | m_sumRtt |
Additional Inherited Members | |
![]() | |
enum | TestDuration { QUICK = 1, EXTENSIVE = 2, TAKES_FOREVER = 3 } |
How long the test takes to execute. More... | |
![]() | |
TestCase (std::string name) | |
Constructor. More... | |
void | AddTestCase (TestCase *testCase, enum TestDuration duration) |
Add an individual child TestCase to this test suite. More... | |
TestCase * | GetParent () const |
Get the parent of this TestCsse. More... | |
bool | IsStatusFailure (void) const |
Check if any tests failed. More... | |
bool | IsStatusSuccess (void) const |
Check if all tests passed. More... | |
void | SetDataDir (std::string directory) |
Set the data directory where reference trace files can be found. More... | |
void | ReportTestFailure (std::string cond, std::string actual, std::string limit, std::string message, std::string file, int32_t line) |
Log the failure of this TestCase. More... | |
bool | MustAssertOnFailure (void) const |
Check if this run should assert on failure. More... | |
bool | MustContinueOnFailure (void) const |
Check if this run should continue on failure. More... | |
std::string | CreateDataDirFilename (std::string filename) |
Construct the full path to a file in the data directory. More... | |
std::string | CreateTempDirFilename (std::string filename) |
Construct the full path to a file in a temporary directory. More... | |
Testing TcpIllinois C-AIMD algorithm.
Definition at line 40 of file tcp-illinois-test.cc.
ns3::TcpIllinoisTest::TcpIllinoisTest | ( | uint32_t | cWnd, |
uint32_t | ssThresh, | ||
uint32_t | segmentSize, | ||
uint32_t | cntRtt, | ||
Time | maxRtt, | ||
uint32_t | segmentsAcked, | ||
SequenceNumber32 | nextTxSeq, | ||
SequenceNumber32 | lastAckedSeq, | ||
const std::string & | name | ||
) |
Definition at line 80 of file tcp-illinois-test.cc.
|
private |
Definition at line 233 of file tcp-illinois-test.cc.
References ns3::DoubleValue::Get(), ns3::UintegerValue::Get(), m_alpha, m_rttAbove, m_rttLow, and NS_LOG_INFO.
Referenced by RecalcParam().
|
private |
Definition at line 227 of file tcp-illinois-test.cc.
References m_baseRtt, m_cntRtt, and m_sumRtt.
Referenced by RecalcParam().
|
private |
Definition at line 268 of file tcp-illinois-test.cc.
References ns3::DoubleValue::Get(), m_beta, and NS_LOG_INFO.
Referenced by RecalcParam().
|
private |
Definition at line 221 of file tcp-illinois-test.cc.
References m_baseRtt, and m_maxRtt.
Referenced by RecalcParam().
|
privatevirtual |
Implementation to actually run this TestCase.
Subclasses should override this method to conduct their tests.
Implements ns3::TestCase.
Definition at line 109 of file tcp-illinois-test.cc.
References GetSsThresh(), IncreaseWindow(), m_baseRtt, m_cntRtt, m_cWnd, m_lastAckedSeq, m_maxRtt, m_nextTxSeq, m_segmentsAcked, m_segmentSize, m_ssThresh, m_sumRtt, and NS_TEST_ASSERT_MSG_EQ.
|
private |
Definition at line 296 of file tcp-illinois-test.cc.
References m_beta, m_cWnd, m_segmentSize, m_ssThresh, max, and NS_LOG_DEBUG.
Referenced by DoRun().
|
private |
Definition at line 152 of file tcp-illinois-test.cc.
References m_ackCnt, m_alpha, m_cWnd, m_lastAckedSeq, m_nextTxSeq, m_segmentsAcked, m_segmentSize, m_ssThresh, NS_LOG_INFO, and RecalcParam().
Referenced by DoRun().
|
private |
Definition at line 196 of file tcp-illinois-test.cc.
References CalculateAlpha(), CalculateAvgDelay(), CalculateBeta(), CalculateMaxDelay(), ns3::DoubleValue::Get(), ns3::UintegerValue::Get(), ns3::Time::GetMilliSeconds(), m_alpha, m_cntRtt, m_cWnd, and NS_LOG_INFO.
Referenced by IncreaseWindow().
|
private |
Definition at line 77 of file tcp-illinois-test.cc.
Referenced by IncreaseWindow().
|
private |
Definition at line 71 of file tcp-illinois-test.cc.
Referenced by CalculateAlpha(), IncreaseWindow(), and RecalcParam().
|
private |
Definition at line 66 of file tcp-illinois-test.cc.
Referenced by CalculateAvgDelay(), CalculateMaxDelay(), and DoRun().
|
private |
Definition at line 72 of file tcp-illinois-test.cc.
Referenced by CalculateBeta(), and GetSsThresh().
|
private |
Definition at line 73 of file tcp-illinois-test.cc.
Referenced by CalculateAvgDelay(), DoRun(), and RecalcParam().
|
private |
Definition at line 63 of file tcp-illinois-test.cc.
Referenced by DoRun(), GetSsThresh(), IncreaseWindow(), and RecalcParam().
|
private |
Definition at line 70 of file tcp-illinois-test.cc.
Referenced by DoRun(), and IncreaseWindow().
|
private |
Definition at line 67 of file tcp-illinois-test.cc.
Referenced by CalculateMaxDelay(), and DoRun().
|
private |
Definition at line 69 of file tcp-illinois-test.cc.
Referenced by DoRun(), and IncreaseWindow().
|
private |
Definition at line 75 of file tcp-illinois-test.cc.
Referenced by CalculateAlpha().
|
private |
Definition at line 76 of file tcp-illinois-test.cc.
Referenced by CalculateAlpha().
|
private |
Definition at line 68 of file tcp-illinois-test.cc.
Referenced by DoRun(), and IncreaseWindow().
|
private |
Definition at line 65 of file tcp-illinois-test.cc.
Referenced by DoRun(), GetSsThresh(), and IncreaseWindow().
|
private |
Definition at line 64 of file tcp-illinois-test.cc.
Referenced by DoRun(), GetSsThresh(), and IncreaseWindow().
|
private |
Definition at line 74 of file tcp-illinois-test.cc.
Referenced by CalculateAvgDelay(), and DoRun().