Fix whitespace issues
Change-Id: I7c96843996f4847f9e15022f1dc6cd85e8a092f7
diff --git a/TestON/examples/Assert/Assert.py b/TestON/examples/Assert/Assert.py
index bc2ce2e..0df0a49 100644
--- a/TestON/examples/Assert/Assert.py
+++ b/TestON/examples/Assert/Assert.py
@@ -11,7 +11,7 @@
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with TestON. If not, see <http://www.gnu.org/licenses/>.
+ along with TestON. If not, see <http://www.gnu.org/licenses/>.
'''
@@ -22,24 +22,24 @@
def CASE1(self,main) :
-
+
main.case("Using assert to verify the result")
main.step("Using assert_equal to verify the result is equivalent or not")
expect = main.TRUE
actual = main.TRUE
main.log.warn(main.response_parser('<real></real><imag>2</imag><__complex__>true</__complex__>', "json"))
utilities.assert_equals(expect=expect,actual=actual,onpass="expect is equal to actual",onfail="expect is not equal to actual")
-
+
main.step("Using assert_matches to verify the result matches or not")
expect = "Res(.*)"
actual = "Result"
utilities.assert_matches(expect=expect,actual=actual,onpass="expect is macthes to actual",onfail="expect is not matches to actual")
-
+
main.step("Using assert_greater to verify the result greater or not")
expect = 10
actual = 5
utilities.assert_greater(expect=actual,actual=expect,onpass="expect is greater than the actual",onfail="expect is not greater than the actual")
-
+
main.step("Using assert_lesser to verify the result lesser or not")
expect = 5
actual = 10
diff --git a/TestON/examples/CaseParams/CaseParams.py b/TestON/examples/CaseParams/CaseParams.py
index 0502c46..d988c14 100644
--- a/TestON/examples/CaseParams/CaseParams.py
+++ b/TestON/examples/CaseParams/CaseParams.py
@@ -15,27 +15,27 @@
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with TestON. If not, see <http://www.gnu.org/licenses/>.
+ along with TestON. If not, see <http://www.gnu.org/licenses/>.
-'''
+'''
class CaseParams:
'''
This example shows the usage of the CASE level parameters, in params file the
[[CASE]]
'destination' = 'h2'
-
+
We can get this CASE level parameter like :
main.params['CASE1']['destination']
-
-
+
+
cd ~/bin/
ofautomation>run CaseParams example 1
will execute this example.
'''
-
+
def __init__(self):
self.default = ""
-
+
def CASE1(self,main):
'''
This test case will showcase usage of CASE level parameters to specify the host as h2
@@ -44,8 +44,8 @@
main.step("Host IP Checking using checkIP")
result = main.Mininet1.checkIP(main.params['CASE1']['destination'])
main.step("Verifying the result")
- utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
-
+ utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
+
def CASE2(self,main):
'''
@@ -55,4 +55,4 @@
main.step("Host IP Checking using checkIP")
result = main.Mininet1.checkIP(main.params['CASE2']['destination'])
main.step("Verifying the result")
- utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h3 IP address configured",onfail="Host h3 IP address didn't configured")
+ utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h3 IP address configured",onfail="Host h3 IP address didn't configured")
diff --git a/TestON/examples/ExperimentTest/ExperimentTest.py b/TestON/examples/ExperimentTest/ExperimentTest.py
index 7630703..9e80dd2 100644
--- a/TestON/examples/ExperimentTest/ExperimentTest.py
+++ b/TestON/examples/ExperimentTest/ExperimentTest.py
@@ -1,7 +1,7 @@
#!/usr/bin/env python
-'''
+'''
Created on 26-Nov-2012
-
+
@author: Raghav Kashyap(raghavkashyap@paxterrasolutions.com)
@@ -16,7 +16,7 @@
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with TestON. If not, see <http://www.gnu.org/licenses/>.
+ along with TestON. If not, see <http://www.gnu.org/licenses/>.
Testing of the Experimental Mode
@@ -25,13 +25,13 @@
'''
class ExperimentTest:
'''
- Testing of the Experimental Mode
-
+ Testing of the Experimental Mode
+
'''
-
+
def __init__(self):
self.default = ""
-
+
def CASE1(self,main):
'''
Testing the configuration of the host by using checkIP functionof Mininet driver
@@ -41,8 +41,8 @@
main.step("Host IP Checking using checkIP")
result = main.Mininet1.checkIP(main.params['CASE1']['destination'])
main.step("Verifying the result")
- utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
- main.step("Calling Non Existing API for Experimental Mode")
+ utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
+ main.step("Calling Non Existing API for Experimental Mode")
testReturn = main.POX2.verify_flow(returns=main.TRUE)
utilities.assert_equals(expect=main.TRUE,actual=testReturn,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
@@ -56,7 +56,7 @@
result = main.Mininet1.pingall()
main.step("Verifying the result")
utilities.assert_equals(expect=main.TRUE,actual=result,onpass="All hosts are reacchable",onfail="Hosts are not reachable")
- main.step("Calling Non Existing API for Experimental Mode")
+ main.step("Calling Non Existing API for Experimental Mode")
testReturn = main.Mininet1.verify_flow(returns=main.TRUE)
utilities.assert_equals(expect=main.TRUE,actual=testReturn,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
-
+
diff --git a/TestON/examples/StepParams/StepParams.py b/TestON/examples/StepParams/StepParams.py
index 10cfd69..7e4c2fa 100644
--- a/TestON/examples/StepParams/StepParams.py
+++ b/TestON/examples/StepParams/StepParams.py
@@ -16,24 +16,24 @@
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with TestON. If not, see <http://www.gnu.org/licenses/>.
-'''
+ along with TestON. If not, see <http://www.gnu.org/licenses/>.
+'''
class StepParams:
- '''
+ '''
This example shows the usage of the STEP level parameters, in params file the
[[CASE1]]
[[[STEP1]]]
'host' = 'h2'
-
+
We can get this STEP level parameter like :
main.params['CASE1']['STEP1']['host']
-
-
- ofautomation>run StepParams example 1
+
+
+ ofautomation>run StepParams example 1
'''
def __init__(self):
self.default = ""
-
+
def CASE1(self,main):
'''
This example will showcase the usage of STEP level parameters to specify the host as h2
@@ -42,8 +42,8 @@
main.step("Host IP Checking using checkIP")
result = main.Mininet1.checkIP(main.params['CASE1']['STEP1']['host'])
main.step("Verifying the result")
- utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
-
+ utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
+
def CASE2(self,main):
'''
@@ -53,4 +53,4 @@
main.step("Host IP Checking using checkIP")
result = main.Mininet1.checkIP(main.params['CASE2']['STEP1']['host'])
main.step("Verifying the result")
- utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h3 IP address configured",onfail="Host h3 IP address didn't configured")
+ utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h3 IP address configured",onfail="Host h3 IP address didn't configured")
diff --git a/TestON/examples/Topology/Topology.py b/TestON/examples/Topology/Topology.py
index 775535c..efccde9 100644
--- a/TestON/examples/Topology/Topology.py
+++ b/TestON/examples/Topology/Topology.py
@@ -16,33 +16,33 @@
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with TestON. If not, see <http://www.gnu.org/licenses/>.
-'''
+ along with TestON. If not, see <http://www.gnu.org/licenses/>.
+'''
class Topology:
'''
-
+
This example shows, how we can use the topology file:
-
+
In topo file we can specify the component like below:
- [TOPOLOGY]
-
+ [TOPOLOGY]
+
[[COMPONENT]]
[[["Mininet1"]]]
-
+
The usage of this component in the test script like below:
-
+
main.Mininet1.checkIP(main.params['CASE1']['destination'])
-
- Here we are using the Mininet1 which of type Mininet
-
-
-
+
+ Here we are using the Mininet1 which of type Mininet
+
+
+
ofautomation>run Topology example 1
will execute this example.
'''
def __init__(self):
self.default = ""
-
+
def CASE1(self,main):
'''
This will showcase the usage of Topology
@@ -51,6 +51,6 @@
main.step("Mininet1 specified in Topology , using the Mininet1 to check host ip")
result = main.Mininet1.checkIP(main.params['CASE1']['destination'])
main.step("Verifying the result")
- utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
-
-
+ utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
+
+