author | Vedran Miletić <rivanvx@gmail.com> |
Tue, 02 Aug 2011 17:42:33 -0400 | |
changeset 7385 | 10beb0e53130 |
parent 7141 | 072fb225b714 |
child 9176 | 41ab1e874804 |
permissions | -rw-r--r-- |
7385
10beb0e53130
standardize emacs c++ mode comments
Vedran Miletić <rivanvx@gmail.com>
parents:
7141
diff
changeset
|
1 |
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ |
4325
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
2 |
/* |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
3 |
* Copyright (c) 2005,2006 INRIA |
6665 | 4 |
* 2010 NICTA |
4325
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
5 |
* |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
6 |
* This program is free software; you can redistribute it and/or modify |
7141
072fb225b714
run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents:
7061
diff
changeset
|
7 |
* it under the terms of the GNU General Public License version 2 as |
4325
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
8 |
* published by the Free Software Foundation; |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
9 |
* |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
10 |
* This program is distributed in the hope that it will be useful, |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
11 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
12 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
13 |
* GNU General Public License for more details. |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
14 |
* |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
15 |
* You should have received a copy of the GNU General Public License |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
16 |
* along with this program; if not, write to the Free Software |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
17 |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
18 |
* |
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
19 |
* Author: Mathieu Lacage <mathieu.lacage@sophia.inria.fr> |
6665 | 20 |
* Quincy Tse <quincy.tse@nicta.com.au> (Case for Bug 991) |
4325
acc6c801f785
bug 548: missing license header
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4257
diff
changeset
|
21 |
*/ |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
22 |
|
6848
1f453ad50ef3
Converts csma, emu, tap-bridge, point-to-point, wifi and wimax modules into modular format
Lalith Suresh <suresh.lalith@gmail.com>
parents:
6803
diff
changeset
|
23 |
#include "ns3/wifi-net-device.h" |
1f453ad50ef3
Converts csma, emu, tap-bridge, point-to-point, wifi and wimax modules into modular format
Lalith Suresh <suresh.lalith@gmail.com>
parents:
6803
diff
changeset
|
24 |
#include "ns3/yans-wifi-channel.h" |
1f453ad50ef3
Converts csma, emu, tap-bridge, point-to-point, wifi and wimax modules into modular format
Lalith Suresh <suresh.lalith@gmail.com>
parents:
6803
diff
changeset
|
25 |
#include "ns3/adhoc-wifi-mac.h" |
1f453ad50ef3
Converts csma, emu, tap-bridge, point-to-point, wifi and wimax modules into modular format
Lalith Suresh <suresh.lalith@gmail.com>
parents:
6803
diff
changeset
|
26 |
#include "ns3/yans-wifi-phy.h" |
1f453ad50ef3
Converts csma, emu, tap-bridge, point-to-point, wifi and wimax modules into modular format
Lalith Suresh <suresh.lalith@gmail.com>
parents:
6803
diff
changeset
|
27 |
#include "ns3/arf-wifi-manager.h" |
5944
b1a245ae00d4
Moving the propagation models of wifi from src/devices/wifi to src/common. The idea is to share them with the other wireless devices.
Mohamed Amine Ismail <amine.ismail@sophia.inria.fr>
parents:
5919
diff
changeset
|
28 |
#include "ns3/propagation-delay-model.h" |
b1a245ae00d4
Moving the propagation models of wifi from src/devices/wifi to src/common. The idea is to share them with the other wireless devices.
Mohamed Amine Ismail <amine.ismail@sophia.inria.fr>
parents:
5919
diff
changeset
|
29 |
#include "ns3/propagation-loss-model.h" |
6848
1f453ad50ef3
Converts csma, emu, tap-bridge, point-to-point, wifi and wimax modules into modular format
Lalith Suresh <suresh.lalith@gmail.com>
parents:
6803
diff
changeset
|
30 |
#include "ns3/error-rate-model.h" |
1f453ad50ef3
Converts csma, emu, tap-bridge, point-to-point, wifi and wimax modules into modular format
Lalith Suresh <suresh.lalith@gmail.com>
parents:
6803
diff
changeset
|
31 |
#include "ns3/yans-error-rate-model.h" |
4257
3e8f8052e155
StaticMobilityModel -> ConstantPositionMobilityModel, StaticSpeedMobilityModel -> ConstantVelocityMobilityModel
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4038
diff
changeset
|
32 |
#include "ns3/constant-position-mobility-model.h" |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
33 |
#include "ns3/node.h" |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
34 |
#include "ns3/simulator.h" |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
35 |
#include "ns3/test.h" |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
36 |
#include "ns3/object-factory.h" |
6848
1f453ad50ef3
Converts csma, emu, tap-bridge, point-to-point, wifi and wimax modules into modular format
Lalith Suresh <suresh.lalith@gmail.com>
parents:
6803
diff
changeset
|
37 |
#include "ns3/dca-txop.h" |
1f453ad50ef3
Converts csma, emu, tap-bridge, point-to-point, wifi and wimax modules into modular format
Lalith Suresh <suresh.lalith@gmail.com>
parents:
6803
diff
changeset
|
38 |
#include "ns3/mac-rx-middle.h" |
4406 | 39 |
#include "ns3/pointer.h" |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
40 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
41 |
namespace ns3 { |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
42 |
|
5320
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
43 |
class WifiTest : public TestCase |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
44 |
{ |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
45 |
public: |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
46 |
WifiTest (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
47 |
|
6775
0783f42a364b
Make test cases not return bool valuesMake all TestSuite instances be static
Mitch Watrous <watrous@u.washington.edu>
parents:
6774
diff
changeset
|
48 |
virtual void DoRun (void); |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
49 |
private: |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
50 |
void RunOne (void); |
3912
4d1a61f80745
new wifi API
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3893
diff
changeset
|
51 |
void CreateOne (Vector pos, Ptr<YansWifiChannel> channel); |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
52 |
void SendOnePacket (Ptr<WifiNetDevice> dev); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
53 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
54 |
ObjectFactory m_manager; |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
55 |
ObjectFactory m_mac; |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
56 |
ObjectFactory m_propDelay; |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
57 |
}; |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
58 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
59 |
WifiTest::WifiTest () |
5320
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
60 |
: TestCase ("Wifi") |
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
61 |
{ |
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
62 |
} |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
63 |
|
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
64 |
void |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
65 |
WifiTest::SendOnePacket (Ptr<WifiNetDevice> dev) |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
66 |
{ |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
67 |
Ptr<Packet> p = Create<Packet> (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
68 |
dev->Send (p, dev->GetBroadcast (), 1); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
69 |
} |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
70 |
|
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
71 |
void |
3912
4d1a61f80745
new wifi API
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3893
diff
changeset
|
72 |
WifiTest::CreateOne (Vector pos, Ptr<YansWifiChannel> channel) |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
73 |
{ |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
74 |
Ptr<Node> node = CreateObject<Node> (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
75 |
Ptr<WifiNetDevice> dev = CreateObject<WifiNetDevice> (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
76 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
77 |
Ptr<WifiMac> mac = m_mac.Create<WifiMac> (); |
4720
15221757964f
bug 641: CwMin setting for 802.11b
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4406
diff
changeset
|
78 |
mac->ConfigureStandard (WIFI_PHY_STANDARD_80211a); |
4257
3e8f8052e155
StaticMobilityModel -> ConstantPositionMobilityModel, StaticSpeedMobilityModel -> ConstantVelocityMobilityModel
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4038
diff
changeset
|
79 |
Ptr<ConstantPositionMobilityModel> mobility = CreateObject<ConstantPositionMobilityModel> (); |
3912
4d1a61f80745
new wifi API
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3893
diff
changeset
|
80 |
Ptr<YansWifiPhy> phy = CreateObject<YansWifiPhy> (); |
4038
c6f634d0fc6f
virtualize ErrorRateModel
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3912
diff
changeset
|
81 |
Ptr<ErrorRateModel> error = CreateObject<YansErrorRateModel> (); |
3912
4d1a61f80745
new wifi API
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3893
diff
changeset
|
82 |
phy->SetErrorRateModel (error); |
4d1a61f80745
new wifi API
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3893
diff
changeset
|
83 |
phy->SetChannel (channel); |
4d1a61f80745
new wifi API
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3893
diff
changeset
|
84 |
phy->SetDevice (dev); |
4d1a61f80745
new wifi API
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3893
diff
changeset
|
85 |
phy->SetMobility (node); |
4720
15221757964f
bug 641: CwMin setting for 802.11b
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4406
diff
changeset
|
86 |
phy->ConfigureStandard (WIFI_PHY_STANDARD_80211a); |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
87 |
Ptr<WifiRemoteStationManager> manager = m_manager.Create<WifiRemoteStationManager> (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
88 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
89 |
mobility->SetPosition (pos); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
90 |
node->AggregateObject (mobility); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
91 |
mac->SetAddress (Mac48Address::Allocate ()); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
92 |
dev->SetMac (mac); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
93 |
dev->SetPhy (phy); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
94 |
dev->SetRemoteStationManager (manager); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
95 |
node->AddDevice (dev); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
96 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
97 |
Simulator::Schedule (Seconds (1.0), &WifiTest::SendOnePacket, this, dev); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
98 |
} |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
99 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
100 |
void |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
101 |
WifiTest::RunOne (void) |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
102 |
{ |
3893
94f771c1373a
split WifiChannel in WifiChannel + YansWifiChannel
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
3888
diff
changeset
|
103 |
Ptr<YansWifiChannel> channel = CreateObject<YansWifiChannel> (); |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
104 |
Ptr<PropagationDelayModel> propDelay = m_propDelay.Create<PropagationDelayModel> (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
105 |
Ptr<PropagationLossModel> propLoss = CreateObject<RandomPropagationLossModel> (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
106 |
channel->SetPropagationDelayModel (propDelay); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
107 |
channel->SetPropagationLossModel (propLoss); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
108 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
109 |
CreateOne (Vector (0.0, 0.0, 0.0), channel); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
110 |
CreateOne (Vector (5.0, 0.0, 0.0), channel); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
111 |
CreateOne (Vector (5.0, 0.0, 0.0), channel); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
112 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
113 |
Simulator::Run (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
114 |
Simulator::Destroy (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
115 |
|
3174
efeb6e5c276d
Make Application::Start/Stop times relative, Simulator::StopAt(time) renamed to Simulator::Stop(time) and time also made relative, to improve consistency of the API which uses relative times everywhere else. Closes bug #191.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
2627
diff
changeset
|
116 |
Simulator::Stop (Seconds (10.0)); |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
117 |
} |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
118 |
|
6775
0783f42a364b
Make test cases not return bool valuesMake all TestSuite instances be static
Mitch Watrous <watrous@u.washington.edu>
parents:
6774
diff
changeset
|
119 |
void |
5320
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
120 |
WifiTest::DoRun (void) |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
121 |
{ |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
122 |
m_mac.SetTypeId ("ns3::AdhocWifiMac"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
123 |
m_propDelay.SetTypeId ("ns3::ConstantSpeedPropagationDelayModel"); |
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
124 |
|
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
125 |
m_manager.SetTypeId ("ns3::ArfWifiManager"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
126 |
RunOne (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
127 |
m_manager.SetTypeId ("ns3::AarfWifiManager"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
128 |
RunOne (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
129 |
m_manager.SetTypeId ("ns3::ConstantRateWifiManager"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
130 |
RunOne (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
131 |
m_manager.SetTypeId ("ns3::OnoeWifiManager"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
132 |
RunOne (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
133 |
m_manager.SetTypeId ("ns3::AmrrWifiManager"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
134 |
RunOne (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
135 |
m_manager.SetTypeId ("ns3::IdealWifiManager"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
136 |
RunOne (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
137 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
138 |
m_mac.SetTypeId ("ns3::AdhocWifiMac"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
139 |
RunOne (); |
6673
ec22aa763e2d
Bug 978: Consolidate Wi-Fi MAC high functionality
Dean Armstrong <deanarm@gmail.com>
parents:
6665
diff
changeset
|
140 |
m_mac.SetTypeId ("ns3::ApWifiMac"); |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
141 |
RunOne (); |
6673
ec22aa763e2d
Bug 978: Consolidate Wi-Fi MAC high functionality
Dean Armstrong <deanarm@gmail.com>
parents:
6665
diff
changeset
|
142 |
m_mac.SetTypeId ("ns3::StaWifiMac"); |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
143 |
RunOne (); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
144 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
145 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
146 |
m_propDelay.SetTypeId ("ns3::RandomPropagationDelayModel"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
147 |
m_mac.SetTypeId ("ns3::AdhocWifiMac"); |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
148 |
RunOne (); |
5919
b89ce2e9eed5
Bug 793: remove remaining memory leaks due to not cleaned Simulator
Faker Moatamri <faker.moatamri@sophia.inria.fr>
parents:
5320
diff
changeset
|
149 |
Simulator::Destroy (); |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
150 |
} |
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
151 |
|
5320
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
152 |
//----------------------------------------------------------------------------- |
6600
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
153 |
class QosUtilsIsOldPacketTest : public TestCase |
5320
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
154 |
{ |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
155 |
public: |
7141
072fb225b714
run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents:
7061
diff
changeset
|
156 |
QosUtilsIsOldPacketTest () : TestCase ("QosUtilsIsOldPacket") |
072fb225b714
run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents:
7061
diff
changeset
|
157 |
{ |
072fb225b714
run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents:
7061
diff
changeset
|
158 |
} |
6775
0783f42a364b
Make test cases not return bool valuesMake all TestSuite instances be static
Mitch Watrous <watrous@u.washington.edu>
parents:
6774
diff
changeset
|
159 |
virtual void DoRun (void) |
5320
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
160 |
{ |
6600
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
161 |
// startingSeq=0, seqNum=2047 |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
162 |
NS_TEST_EXPECT_MSG_EQ (QosUtilsIsOldPacket (0, 2047), false, "2047 is new in comparison to 0"); |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
163 |
// startingSeq=0, seqNum=2048 |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
164 |
NS_TEST_EXPECT_MSG_EQ (QosUtilsIsOldPacket (0, 2048), true, "2048 is old in comparison to 0"); |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
165 |
// startingSeq=2048, seqNum=0 |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
166 |
NS_TEST_EXPECT_MSG_EQ (QosUtilsIsOldPacket (2048, 0), true, "0 is old in comparison to 2048"); |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
167 |
// startingSeq=4095, seqNum=0 |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
168 |
NS_TEST_EXPECT_MSG_EQ (QosUtilsIsOldPacket (4095, 0), false, "0 is new in comparison to 4095"); |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
169 |
// startingSeq=0, seqNum=4095 |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
170 |
NS_TEST_EXPECT_MSG_EQ (QosUtilsIsOldPacket (0, 4095), true, "4095 is old in comparison to 0"); |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
171 |
// startingSeq=4095 seqNum=2047 |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
172 |
NS_TEST_EXPECT_MSG_EQ (QosUtilsIsOldPacket (4095, 2047), true, "2047 is old in comparison to 4095"); |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
173 |
// startingSeq=2048 seqNum=4095 |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
174 |
NS_TEST_EXPECT_MSG_EQ (QosUtilsIsOldPacket (2048, 4095), false, "4095 is new in comparison to 2048"); |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
175 |
// startingSeq=2049 seqNum=0 |
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
176 |
NS_TEST_EXPECT_MSG_EQ (QosUtilsIsOldPacket (2049, 0), false, "0 is new in comparison to 2049"); |
5320
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
177 |
} |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
178 |
}; |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
179 |
|
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
180 |
//----------------------------------------------------------------------------- |
6665 | 181 |
class InterferenceHelperSequenceTest : public TestCase |
182 |
{ |
|
183 |
public: |
|
184 |
InterferenceHelperSequenceTest (); |
|
185 |
||
6775
0783f42a364b
Make test cases not return bool valuesMake all TestSuite instances be static
Mitch Watrous <watrous@u.washington.edu>
parents:
6774
diff
changeset
|
186 |
virtual void DoRun (void); |
6665 | 187 |
private: |
188 |
Ptr<Node> CreateOne (Vector pos, Ptr<YansWifiChannel> channel); |
|
189 |
void SendOnePacket (Ptr<WifiNetDevice> dev); |
|
190 |
void SwitchCh (Ptr<WifiNetDevice> dev); |
|
191 |
||
192 |
ObjectFactory m_manager; |
|
193 |
ObjectFactory m_mac; |
|
194 |
ObjectFactory m_propDelay; |
|
195 |
}; |
|
196 |
||
197 |
InterferenceHelperSequenceTest::InterferenceHelperSequenceTest () |
|
198 |
: TestCase ("InterferenceHelperSequence") |
|
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
199 |
{ |
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
200 |
} |
6665 | 201 |
|
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
202 |
void |
6665 | 203 |
InterferenceHelperSequenceTest::SendOnePacket (Ptr<WifiNetDevice> dev) |
204 |
{ |
|
205 |
Ptr<Packet> p = Create<Packet> (9999); |
|
206 |
dev->Send (p, dev->GetBroadcast (), 1); |
|
207 |
} |
|
208 |
||
209 |
void |
|
210 |
InterferenceHelperSequenceTest::SwitchCh (Ptr<WifiNetDevice> dev) |
|
211 |
{ |
|
212 |
Ptr<WifiPhy> p = dev->GetPhy (); |
|
213 |
p->SetChannelNumber (1); |
|
214 |
} |
|
215 |
||
216 |
Ptr<Node> |
|
217 |
InterferenceHelperSequenceTest::CreateOne (Vector pos, Ptr<YansWifiChannel> channel) |
|
218 |
{ |
|
219 |
Ptr<Node> node = CreateObject<Node> (); |
|
220 |
Ptr<WifiNetDevice> dev = CreateObject<WifiNetDevice> (); |
|
221 |
||
222 |
Ptr<WifiMac> mac = m_mac.Create<WifiMac> (); |
|
223 |
mac->ConfigureStandard (WIFI_PHY_STANDARD_80211a); |
|
224 |
Ptr<ConstantPositionMobilityModel> mobility = CreateObject<ConstantPositionMobilityModel> (); |
|
225 |
Ptr<YansWifiPhy> phy = CreateObject<YansWifiPhy> (); |
|
226 |
Ptr<ErrorRateModel> error = CreateObject<YansErrorRateModel> (); |
|
227 |
phy->SetErrorRateModel (error); |
|
228 |
phy->SetChannel (channel); |
|
229 |
phy->SetDevice (dev); |
|
230 |
phy->SetMobility (node); |
|
231 |
phy->ConfigureStandard (WIFI_PHY_STANDARD_80211a); |
|
232 |
Ptr<WifiRemoteStationManager> manager = m_manager.Create<WifiRemoteStationManager> (); |
|
233 |
||
234 |
mobility->SetPosition (pos); |
|
235 |
node->AggregateObject (mobility); |
|
236 |
mac->SetAddress (Mac48Address::Allocate ()); |
|
237 |
dev->SetMac (mac); |
|
238 |
dev->SetPhy (phy); |
|
239 |
dev->SetRemoteStationManager (manager); |
|
240 |
node->AddDevice (dev); |
|
241 |
||
242 |
return node; |
|
243 |
} |
|
244 |
||
6775
0783f42a364b
Make test cases not return bool valuesMake all TestSuite instances be static
Mitch Watrous <watrous@u.washington.edu>
parents:
6774
diff
changeset
|
245 |
void |
6665 | 246 |
InterferenceHelperSequenceTest::DoRun (void) |
247 |
{ |
|
248 |
m_mac.SetTypeId ("ns3::AdhocWifiMac"); |
|
249 |
m_propDelay.SetTypeId ("ns3::ConstantSpeedPropagationDelayModel"); |
|
250 |
m_manager.SetTypeId ("ns3::ConstantRateWifiManager"); |
|
251 |
||
252 |
Ptr<YansWifiChannel> channel = CreateObject<YansWifiChannel> (); |
|
253 |
Ptr<PropagationDelayModel> propDelay = m_propDelay.Create<PropagationDelayModel> (); |
|
254 |
Ptr<MatrixPropagationLossModel> propLoss = CreateObject<MatrixPropagationLossModel> (); |
|
255 |
channel->SetPropagationDelayModel (propDelay); |
|
256 |
channel->SetPropagationLossModel (propLoss); |
|
257 |
||
258 |
Ptr<Node> rxOnly = CreateOne (Vector (0.0, 0.0, 0.0), channel); |
|
259 |
Ptr<Node> senderA = CreateOne (Vector (5.0, 0.0, 0.0), channel); |
|
260 |
Ptr<Node> senderB = CreateOne (Vector (-5.0, 0.0, 0.0), channel); |
|
261 |
||
7141
072fb225b714
run check-style.py on src/wifi
Nicola Baldo <nicola@baldo.biz>
parents:
7061
diff
changeset
|
262 |
propLoss->SetLoss (senderB->GetObject<MobilityModel> (), rxOnly->GetObject<MobilityModel> (), 0, true); |
6665 | 263 |
propLoss->SetDefaultLoss (999); |
264 |
||
265 |
Simulator::Schedule (Seconds (1.0), |
|
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
266 |
&InterferenceHelperSequenceTest::SendOnePacket, this, |
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
267 |
DynamicCast<WifiNetDevice> (senderB->GetDevice (0))); |
6665 | 268 |
|
269 |
Simulator::Schedule (Seconds (1.0000001), |
|
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
270 |
&InterferenceHelperSequenceTest::SwitchCh, this, |
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
271 |
DynamicCast<WifiNetDevice> (rxOnly->GetDevice (0))); |
6665 | 272 |
|
273 |
Simulator::Schedule (Seconds (5.0), |
|
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
274 |
&InterferenceHelperSequenceTest::SendOnePacket, this, |
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
275 |
DynamicCast<WifiNetDevice> (senderA->GetDevice (0))); |
6665 | 276 |
|
277 |
Simulator::Schedule (Seconds (7.0), |
|
6674
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
278 |
&InterferenceHelperSequenceTest::SendOnePacket, this, |
52f8688d6d01
Bug 978: Run check-style.py on files touched in the reorganisation
Dean Armstrong <deanarm@gmail.com>
parents:
6673
diff
changeset
|
279 |
DynamicCast<WifiNetDevice> (senderB->GetDevice (0))); |
6665 | 280 |
|
281 |
Simulator::Stop (Seconds (100.0)); |
|
282 |
Simulator::Run (); |
|
283 |
||
284 |
Simulator::Destroy (); |
|
285 |
} |
|
286 |
||
287 |
//----------------------------------------------------------------------------- |
|
5320
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
288 |
|
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
289 |
class WifiTestSuite : public TestSuite |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
290 |
{ |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
291 |
public: |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
292 |
WifiTestSuite (); |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
293 |
}; |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
294 |
|
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
295 |
WifiTestSuite::WifiTestSuite () |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
296 |
: TestSuite ("devices-wifi", UNIT) |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
297 |
{ |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
298 |
AddTestCase (new WifiTest); |
6600
e438f9b17c66
Replace MacRxMiddle::SequenceControlSmaller with QosUtilsIsOldPacket method
Mirko Banchi <mk.banchi@gmail.com>
parents:
5944
diff
changeset
|
299 |
AddTestCase (new QosUtilsIsOldPacketTest); |
6665 | 300 |
AddTestCase (new InterferenceHelperSequenceTest); // Bug 991 |
5320
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
301 |
} |
0fb5a9f1a9c0
wifi unit tests ported to new framework
Pavel Boyko <boyko@iitp.ru>
parents:
4720
diff
changeset
|
302 |
|
6774
034f362af24d
Make all TestSuite instances be static
Mitch Watrous <watrous@u.washington.edu>
parents:
6674
diff
changeset
|
303 |
static WifiTestSuite g_wifiTestSuite; |
2626
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
304 |
|
bc07dd340992
A bunch of wifi smoke tests.
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff
changeset
|
305 |
} // namespace ns3 |