1
2 '''
3 Created on 28-Nov-2012
4
5 @author: Anil Kumar (anilkumar.s@paxterrasolutions.com)
6 '''
8 '''
9 This example shows the usage of the STEP level parameters, in params file the
10 [[CASE1]]
11 [[[STEP1]]]
12 'host' = 'h2'
13
14 We can get this STEP level parameter like :
15 main.params['CASE1']['STEP1']['host']
16
17
18 ofautomation>run StepParams example 1
19 '''
22
24 '''
25 This example will showcase the usage of STEP level parameters to specify the host as h2
26 '''
27 main.case("Using STEP level parameters to specify the host as h2")
28 main.step("Host IP Checking using checkIP")
29 result = main.Mininet1.checkIP(main.params['CASE1']['STEP1']['host'])
30 main.step("Verifying the result")
31 utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h2 IP address configured",onfail="Host h2 IP address didn't configured")
32
33
35 '''
36 This example will showcase the usage of STEP level parameters to specify the host as h3
37 '''
38 main.case("Using STEP level parameters to specify the host as h3")
39 main.step("Host IP Checking using checkIP")
40 result = main.Mininet1.checkIP(main.params['CASE2']['STEP1']['host'])
41 main.step("Verifying the result")
42 utilities.assert_equals(expect=main.TRUE,actual=result,onpass="Host h3 IP address configured",onfail="Host h3 IP address didn't configured")
43