3131
3232BASE_PATH = os .path .dirname (os .path .abspath (__file__ ))
3333CONFIG_PATH = "%s/config/wrapper/env.conf" % BASE_PATH
34- prescript = "%s/config/prescript" % BASE_PATH
35- postscipt = "%s/config/postscript" % BASE_PATH
34+ prescript = "%s/config/prescript" % BASE_PATH
35+ postscipt = "%s/config/postscript" % BASE_PATH
3636NORUNTEST_PATH = "%s/config/wrapper/no_run_tests.conf" % BASE_PATH
3737TEST_CONF_PATH = "%s/config/tests/" % BASE_PATH
3838CONFIGFILE = configparser .SafeConfigParser ()
4848DATA_DIR = "%s/data" % BASE_PATH
4949LOG_DIR = "%s/results" % BASE_PATH
5050logger = logger_init (filepath = BASE_PATH ).getlogger ()
51- prescript_dir = CONFIGFILE .get ('script-dir' , 'prescriptdir' )
52- postscipt_dir = CONFIGFILE .get ('script-dir' , 'postscriptdir' )
51+ prescript_dir = CONFIGFILE .get ('script-dir' , 'prescriptdir' )
52+ postscipt_dir = CONFIGFILE .get ('script-dir' , 'postscriptdir' )
5353
5454
5555class TestSuite ():
@@ -271,7 +271,6 @@ def install_optional_plugin(plugin):
271271 pass
272272
273273
274-
275274def create_config (logdir ):
276275 """
277276 Create the local avocado config file
@@ -350,6 +349,7 @@ def bootstrap(enable_kvm=False):
350349 os .makedirs (postscipt_dir )
351350 helper .copy_dir_file (postscipt , postscipt_dir )
352351
352+
353353def run_test (testsuite , avocado_bin ):
354354 """
355355 To run given testsuite
@@ -392,7 +392,7 @@ def run_test(testsuite, avocado_bin):
392392 if result_link :
393393 result_json = result_link + "/results.json"
394394 result_link += "/job.log\n "
395- with open (result_json , encoding = "utf-8" ) as fp :
395+ with open (result_json , encoding = "utf-8" ) as fp :
396396 result_state = json .load (fp )
397397 for state in ['pass' , 'cancel' , 'errors' , 'failures' , 'skip' , 'warn' , 'interrupt' ]:
398398 if state in result_state .keys ():
@@ -418,6 +418,7 @@ def env_clean():
418418 if os .path .isdir (postscipt_dir ):
419419 helper .remove_file (postscipt , postscipt_dir )
420420
421+
421422def edit_mux_file (test_config_name , mux_file_path , tmp_mux_path ):
422423 """
423424 Edit the mux file with input given in input config file.
0 commit comments