mirror of
https://github.com/httprunner/httprunner.git
synced 2026-05-19 13:59:31 +08:00
bugfix:解决validate为空时沿用上一个接口的validate问题
This commit is contained in:
@@ -146,6 +146,9 @@ class TestContext(ApiServerUnittest):
|
||||
self.context.init_test_variables(variables)
|
||||
self.context.validate(validators, resp_obj)
|
||||
|
||||
self.context.validate([], resp_obj)
|
||||
self.assertEqual(self.context.validation_results, [])
|
||||
|
||||
def test_validate_exception(self):
|
||||
url = "http://127.0.0.1:5000/"
|
||||
resp = requests.get(url)
|
||||
|
||||
Reference in New Issue
Block a user