new feature: support parameters and data driven

This commit is contained in:
debugtalk
2018-02-15 22:53:25 +08:00
parent 2f83777d9a
commit 56cf359810
9 changed files with 294 additions and 7 deletions

View File

@@ -158,3 +158,11 @@ class TestRunner(ApiServerUnittest):
test = testcases[2]["test"]
self.assertTrue(self.test_runner._run_test(test))
def test_run_testset_with_parameters(self):
testcase_file_path = os.path.join(
os.getcwd(), 'tests/data/demo_parameters.yml')
result = run_suite_path(testcase_file_path)
self.assertTrue(result.success)
self.assertIn("token", result.output)
self.assertEqual(result.stat.total, 6)