andrewonlab | 61354f8 | 2014-12-05 16:43:25 -0500 | [diff] [blame] | 1 | |
2 | import time | ||||
3 | import os | ||||
4 | import re | ||||
5 | |||||
kelvin-onlab | 8a83258 | 2015-01-16 17:06:11 -0800 | [diff] [blame] | 6 | |
andrewonlab | 61354f8 | 2014-12-05 16:43:25 -0500 | [diff] [blame] | 7 | class ClassTest: |
kelvin-onlab | 8a83258 | 2015-01-16 17:06:11 -0800 | [diff] [blame] | 8 | |
9 | def __init__( self ): | ||||
andrewonlab | 61354f8 | 2014-12-05 16:43:25 -0500 | [diff] [blame] | 10 | self.default = '' |
11 | |||||
kelvin-onlab | 8a83258 | 2015-01-16 17:06:11 -0800 | [diff] [blame] | 12 | def CASE1( self, main ): |
andrewonlab | 61354f8 | 2014-12-05 16:43:25 -0500 | [diff] [blame] | 13 | import time |
14 | import imp | ||||
15 | |||||
kelvin-onlab | 8a83258 | 2015-01-16 17:06:11 -0800 | [diff] [blame] | 16 | init = imp.load_source( |
17 | 'ClassInit', | ||||
18 | '/home/admin/ONLabTest/TestON/tests/ClassTest/Dependency/ClassInit.py' ) | ||||
andrewonlab | 61354f8 | 2014-12-05 16:43:25 -0500 | [diff] [blame] | 19 | |
kelvin-onlab | 8a83258 | 2015-01-16 17:06:11 -0800 | [diff] [blame] | 20 | ip1_from_class = init.getIp1() |
21 | init.printMain( main ) | ||||
andrewonlab | 61354f8 | 2014-12-05 16:43:25 -0500 | [diff] [blame] | 22 | |
kelvin-onlab | 8a83258 | 2015-01-16 17:06:11 -0800 | [diff] [blame] | 23 | main.log.info( ip1_from_class ) |
andrewonlab | 61354f8 | 2014-12-05 16:43:25 -0500 | [diff] [blame] | 24 | |
kelvin-onlab | 8a83258 | 2015-01-16 17:06:11 -0800 | [diff] [blame] | 25 | def CASE2( self, main ): |
andrewonlab | 61354f8 | 2014-12-05 16:43:25 -0500 | [diff] [blame] | 26 | |
kelvin-onlab | 8a83258 | 2015-01-16 17:06:11 -0800 | [diff] [blame] | 27 | main.log.info( "Case 2" ) |