Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mininet
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Olaf Bergmann
mininet
Commits
84c1c24c
Commit
84c1c24c
authored
10 years ago
by
cody burkard
Browse files
Options
Downloads
Patches
Plain Diff
skip this because of poor UserSwitch performance
parent
af4c9719
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
mininet/test/test_hifi.py
+12
-6
12 additions, 6 deletions
mininet/test/test_hifi.py
with
12 additions
and
6 deletions
mininet/test/test_hifi.py
+
12
−
6
View file @
84c1c24c
...
@@ -45,7 +45,7 @@ def runOptionsTopoTest( self, n, hopts=None, lopts=None ):
...
@@ -45,7 +45,7 @@ def runOptionsTopoTest( self, n, hopts=None, lopts=None ):
mn
=
Mininet
(
topo
=
SingleSwitchOptionsTopo
(
n
=
n
,
hopts
=
hopts
,
mn
=
Mininet
(
topo
=
SingleSwitchOptionsTopo
(
n
=
n
,
hopts
=
hopts
,
lopts
=
lopts
),
lopts
=
lopts
),
host
=
CPULimitedHost
,
link
=
TCLink
,
host
=
CPULimitedHost
,
link
=
TCLink
,
switch
=
self
.
switchClass
)
switch
=
self
.
switchClass
,
waitConnected
=
True
)
dropped
=
mn
.
run
(
mn
.
ping
)
dropped
=
mn
.
run
(
mn
.
ping
)
self
.
assertEqual
(
dropped
,
0
)
self
.
assertEqual
(
dropped
,
0
)
...
@@ -67,7 +67,8 @@ def testCPULimits( self ):
...
@@ -67,7 +67,8 @@ def testCPULimits( self ):
#self.runOptionsTopoTest( N, hopts=hopts )
#self.runOptionsTopoTest( N, hopts=hopts )
mn
=
Mininet
(
SingleSwitchOptionsTopo
(
n
=
N
,
hopts
=
hopts
),
mn
=
Mininet
(
SingleSwitchOptionsTopo
(
n
=
N
,
hopts
=
hopts
),
host
=
CPULimitedHost
,
switch
=
self
.
switchClass
)
host
=
CPULimitedHost
,
switch
=
self
.
switchClass
,
waitConnected
=
True
)
mn
.
start
()
mn
.
start
()
results
=
mn
.
runCpuLimitTest
(
cpu
=
CPU_FRACTION
)
results
=
mn
.
runCpuLimitTest
(
cpu
=
CPU_FRACTION
)
mn
.
stop
()
mn
.
stop
()
...
@@ -77,13 +78,16 @@ def testCPULimits( self ):
...
@@ -77,13 +78,16 @@ def testCPULimits( self ):
def
testLinkBandwidth
(
self
):
def
testLinkBandwidth
(
self
):
"
Verify that link bandwidths are accurate within a bound.
"
"
Verify that link bandwidths are accurate within a bound.
"
BW
=
.
5
# Mbps
if
self
.
switchClass
is
UserSwitch
:
self
.
skipTest
(
'
UserSwitch has very poor performance, so skip for now
'
)
BW
=
5
# Mbps
BW_TOLERANCE
=
0.8
# BW fraction below which test should fail
BW_TOLERANCE
=
0.8
# BW fraction below which test should fail
# Verify ability to create limited-link topo first;
# Verify ability to create limited-link topo first;
lopts
=
{
'
bw
'
:
BW
,
'
use_htb
'
:
True
}
lopts
=
{
'
bw
'
:
BW
,
'
use_htb
'
:
True
}
# Also verify correctness of limit limitng within a bound.
# Also verify correctness of limit limitng within a bound.
mn
=
Mininet
(
SingleSwitchOptionsTopo
(
n
=
N
,
lopts
=
lopts
),
mn
=
Mininet
(
SingleSwitchOptionsTopo
(
n
=
N
,
lopts
=
lopts
),
link
=
TCLink
,
switch
=
self
.
switchClass
)
link
=
TCLink
,
switch
=
self
.
switchClass
,
waitConnected
=
True
)
bw_strs
=
mn
.
run
(
mn
.
iperf
,
format
=
'
m
'
)
bw_strs
=
mn
.
run
(
mn
.
iperf
,
format
=
'
m
'
)
for
bw_str
in
bw_strs
:
for
bw_str
in
bw_strs
:
bw
=
float
(
bw_str
.
split
(
'
'
)[
0
]
)
bw
=
float
(
bw_str
.
split
(
'
'
)[
0
]
)
...
@@ -95,7 +99,8 @@ def testLinkDelay( self ):
...
@@ -95,7 +99,8 @@ def testLinkDelay( self ):
DELAY_TOLERANCE
=
0.8
# Delay fraction below which test should fail
DELAY_TOLERANCE
=
0.8
# Delay fraction below which test should fail
lopts
=
{
'
delay
'
:
'
%sms
'
%
DELAY_MS
,
'
use_htb
'
:
True
}
lopts
=
{
'
delay
'
:
'
%sms
'
%
DELAY_MS
,
'
use_htb
'
:
True
}
mn
=
Mininet
(
SingleSwitchOptionsTopo
(
n
=
N
,
lopts
=
lopts
),
mn
=
Mininet
(
SingleSwitchOptionsTopo
(
n
=
N
,
lopts
=
lopts
),
link
=
TCLink
,
switch
=
self
.
switchClass
,
autoStaticArp
=
True
)
link
=
TCLink
,
switch
=
self
.
switchClass
,
autoStaticArp
=
True
,
waitConnected
=
True
)
ping_delays
=
mn
.
run
(
mn
.
pingFull
)
ping_delays
=
mn
.
run
(
mn
.
pingFull
)
test_outputs
=
ping_delays
[
0
]
test_outputs
=
ping_delays
[
0
]
# Ignore unused variables below
# Ignore unused variables below
...
@@ -117,7 +122,8 @@ def testLinkLoss( self ):
...
@@ -117,7 +122,8 @@ def testLinkLoss( self ):
lopts
=
{
'
loss
'
:
LOSS_PERCENT
,
'
use_htb
'
:
True
}
lopts
=
{
'
loss
'
:
LOSS_PERCENT
,
'
use_htb
'
:
True
}
mn
=
Mininet
(
topo
=
SingleSwitchOptionsTopo
(
n
=
N
,
lopts
=
lopts
),
mn
=
Mininet
(
topo
=
SingleSwitchOptionsTopo
(
n
=
N
,
lopts
=
lopts
),
host
=
CPULimitedHost
,
link
=
TCLink
,
host
=
CPULimitedHost
,
link
=
TCLink
,
switch
=
self
.
switchClass
)
switch
=
self
.
switchClass
,
waitConnected
=
True
)
# Drops are probabilistic, but the chance of no dropped packets is
# Drops are probabilistic, but the chance of no dropped packets is
# 1 in 100 million with 4 hops for a link w/99% loss.
# 1 in 100 million with 4 hops for a link w/99% loss.
dropped_total
=
0
dropped_total
=
0
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment