Fix pexpect isssues/refactor arping command
Change-Id: I03a1db22a176b5dae4f1b02cd8059bd1acfb1d3a
diff --git a/TestON/tests/FUNCintent/Dependency/FuncIntentFunction.py b/TestON/tests/FUNCintent/Dependency/FuncIntentFunction.py
index b1a5d9d..ff886a2 100644
--- a/TestON/tests/FUNCintent/Dependency/FuncIntentFunction.py
+++ b/TestON/tests/FUNCintent/Dependency/FuncIntentFunction.py
@@ -118,8 +118,8 @@
# Discover hosts using arping incase pingall discovery failed
main.log.info( itemName + ": Discover host using arping" )
- main.Mininet1.arping( host=host1 )
- main.Mininet1.arping( host=host2 )
+ main.Mininet1.arping( srcHost=host1, dstHost=host2 )
+ main.Mininet1.arping( srcHost=host2, dstHost=host1 )
host1 = main.CLIs[ 0 ].getHost( mac=h1Mac )
host2 = main.CLIs[ 0 ].getHost( mac=h2Mac )
@@ -1137,10 +1137,8 @@
def pingallHosts( main, hostList ):
# Ping all host in the hosts list variable
- print "Pinging : ", hostList
- pingResult = main.TRUE
- pingResult = main.Mininet1.pingallHosts( hostList )
- return pingResult
+ main.log.info( "Pinging: " + str( hostList ) )
+ return main.Mininet1.pingallHosts( hostList )
def getHostsData( main ):
"""
diff --git a/TestON/tests/FUNCintent/FUNCintent.topo b/TestON/tests/FUNCintent/FUNCintent.topo
index 8b30c31..617e8c0 100755
--- a/TestON/tests/FUNCintent/FUNCintent.topo
+++ b/TestON/tests/FUNCintent/FUNCintent.topo
@@ -40,7 +40,7 @@
</ONOScli3>
<Mininet1>
- <host>localhost</host>
+ <host>OCN</host>
<user>admin</user>
<password></password>
<type>MininetCliDriver</type>
diff --git a/TestON/tests/FUNCintentRest/Dependency/FuncIntentFunction.py b/TestON/tests/FUNCintentRest/Dependency/FuncIntentFunction.py
index 9ce16fe..2dadea4 100644
--- a/TestON/tests/FUNCintentRest/Dependency/FuncIntentFunction.py
+++ b/TestON/tests/FUNCintentRest/Dependency/FuncIntentFunction.py
@@ -112,8 +112,8 @@
# Discover hosts using arping
if not main.hostsData:
main.log.info( itemName + ": Discover host using arping" )
- main.Mininet1.arping( host=host1 )
- main.Mininet1.arping( host=host2 )
+ main.Mininet1.arping( srcHost=host1, dstHost=host2 )
+ main.Mininet1.arping( srcHost=host2, dstHost=host1 )
h1Id = main.CLIs[ 0 ].getHost( mac=h1Mac )
h2Id = main.CLIs[ 0 ].getHost( mac=h2Mac )