OpenVPN 3 Core Library
Loading...
Searching...
No Matches
test_reliable.cpp File Reference
#include "test_common.hpp"
#include <openvpn/common/size.hpp>
#include <openvpn/common/exception.hpp>
#include <openvpn/common/hexstr.hpp>
#include <openvpn/reliable/relack.hpp>
#include <iostream>
#include <string>
#include <sstream>
#include <deque>
#include <algorithm>
#include <limits>
#include <openvpn/random/mtrandapi.hpp>
#include <openvpn/buffer/buffer.hpp>
#include <openvpn/reliable/relrecv.hpp>
#include <openvpn/reliable/relsend.hpp>
#include <openvpn/crypto/packet_id_control.hpp>
Include dependency graph for test_reliable.cpp:

Go to the source code of this file.

Classes

struct  Packet
 
struct  Message
 
struct  test_params
 

Namespaces

namespace  PacketID
 

Typedefs

using PacketID::id_t = openvpn::reliable::id_t
 
typedef ReliableSendTemplate< PacketReliableSend
 
typedef ReliableRecvTemplate< PacketReliableRecv
 

Functions

 TEST (reliable, ack)
 
 TEST (reliable, ack_dup)
 
 TEST (reliable, simple_packet)
 
 OPENVPN_SIMPLE_EXCEPTION (receive_sequence)
 
void print_msg (const Time::Duration t, const char *title, BufferPtr &buf, const openvpn::PacketIDControl::id_t id, std::stringstream &case_detail)
 
void test (MTRand &rand, const Time base, const Time::Duration end, const Time::Duration step, const Time::Duration end_sends, const openvpn::PacketIDControl::id_t relsize, const size_t wiresize, const unsigned int reorder_prob, const unsigned int drop_prob, std::stringstream &case_detail)
 
 TEST (reliable, simulation)
 

Typedef Documentation

◆ ReliableRecv

Definition at line 153 of file test_reliable.cpp.

◆ ReliableSend

Definition at line 152 of file test_reliable.cpp.

Function Documentation

◆ OPENVPN_SIMPLE_EXCEPTION()

OPENVPN_SIMPLE_EXCEPTION ( receive_sequence  )

◆ print_msg()

void print_msg ( const Time::Duration  t,
const char *  title,
BufferPtr buf,
const openvpn::PacketIDControl::id_t  id,
std::stringstream &  case_detail 
)

Definition at line 161 of file test_reliable.cpp.

Here is the caller graph for this function:

◆ test()

void test ( MTRand rand,
const Time  base,
const Time::Duration  end,
const Time::Duration  step,
const Time::Duration  end_sends,
const openvpn::PacketIDControl::id_t  relsize,
const size_t  wiresize,
const unsigned int  reorder_prob,
const unsigned int  drop_prob,
std::stringstream &  case_detail 
)

Definition at line 173 of file test_reliable.cpp.

◆ TEST() [1/4]

TEST ( reliable  ,
ack   
)

Definition at line 29 of file test_reliable.cpp.

◆ TEST() [2/4]

TEST ( reliable  ,
ack_dup   
)

Definition at line 65 of file test_reliable.cpp.

◆ TEST() [3/4]

TEST ( reliable  ,
simple_packet   
)

Definition at line 110 of file test_reliable.cpp.

◆ TEST() [4/4]

TEST ( reliable  ,
simulation   
)

Definition at line 336 of file test_reliable.cpp.