A Discrete-Event Network Simulator
API
hello-regression-test.h
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2009 IITP RAS
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License version 2 as
7  * published by the Free Software Foundation;
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  *
18  * Authors: Pavel Boyko <boyko@iitp.ru>
19  */
20 
21 #ifndef HELLO_REGRESSION_TEST_H
22 #define HELLO_REGRESSION_TEST_H
23 
24 #include "ns3/test.h"
25 #include "ns3/nstime.h"
26 #include "ns3/socket.h"
27 #include "ns3/ipv4-raw-socket-impl.h"
28 #include "ns3/node-container.h"
29 
30 namespace ns3 {
31 namespace olsr {
53 {
54 public:
57 private:
59  const Time m_time;
61  void CreateNodes ();
62  void DoRun ();
63 
68  void ReceivePktProbeA (Ptr<Socket> socket);
70  uint8_t m_countA;
77  void ReceivePktProbeB (Ptr<Socket> socket);
79  uint8_t m_countB;
82 };
83 
84 }
85 }
86 
87 #endif /* HELLO_REGRESSION_TEST_H */
Simulation virtual time values and global simulation resolution.
Definition: nstime.h:102
const Time m_time
Total simulation time.
Trivial (still useful) test of OLSR operation.
encapsulates test code
Definition: test.h:1155
void DoRun()
Implementation to actually run this TestCase.
uint8_t m_countB
Packet counter on node B.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
uint8_t m_countA
Packet counter on node A.
Definition: olsr.py:1
void CreateNodes()
Create & configure test network.
void ReceivePktProbeB(Ptr< Socket > socket)
Receive raw data on node B.
Ptr< Ipv4RawSocketImpl > m_rxSocketB
Receiving socket on node B.
void ReceivePktProbeA(Ptr< Socket > socket)
Receive raw data on node A.
Ptr< Ipv4RawSocketImpl > m_rxSocketA
Receiving socket on node A.