fix #189: remove file path dependency

This commit is contained in:
debugtalk
2018-08-23 16:11:26 +08:00
parent e2ba773e78
commit cb44fafebf
7 changed files with 17 additions and 39 deletions

View File

@@ -80,7 +80,6 @@ class TestRunner(ApiServerUnittest):
start_time = time.time()
config_dict = {
"path": os.path.join(os.getcwd(), __file__),
"name": "basic test with httpbin",
"variables": self.debugtalk_module["variables"],
"functions": self.debugtalk_module["functions"],
@@ -130,7 +129,6 @@ class TestRunner(ApiServerUnittest):
def test_run_testset_with_hooks_modify_request(self):
config_dict = {
"path": os.path.join(os.getcwd(), __file__),
"name": "basic test with httpbin",
"variables": self.debugtalk_module["variables"],
"functions": self.debugtalk_module["functions"],
@@ -185,9 +183,7 @@ class TestRunner(ApiServerUnittest):
],
"teardown_hooks": ["${teardown_hook_sleep_N_secs($response, 2)}"]
}
config_dict = {
"path": os.path.join(os.getcwd(), __file__)
}
config_dict = {}
self.test_runner.init_config(config_dict, "testcase")
start_time = time.time()
@@ -218,9 +214,7 @@ class TestRunner(ApiServerUnittest):
],
"teardown_hooks": ["${teardown_hook_sleep_N_secs($response, 2)}"]
}
config_dict = {
"path": os.path.join(os.getcwd(), __file__)
}
config_dict = {}
self.test_runner.init_config(config_dict, "testcase")
start_time = time.time()
@@ -246,9 +240,7 @@ class TestRunner(ApiServerUnittest):
testcase_file_path = os.path.join(
os.getcwd(), 'tests/data/test_bugfix.yml')
testcases = loader.load_file(testcase_file_path)
config_dict = {
"path": testcase_file_path
}
config_dict = {}
self.test_runner.init_config(config_dict, "testcase")
test = testcases[2]["test"]