update tests for custom validator

This commit is contained in:
httprunner
2017-12-13 16:29:42 +08:00
parent 9401719a1f
commit 5fb87f00f6
2 changed files with 13 additions and 6 deletions

View File

@@ -17,12 +17,13 @@
extract:
- token: content.token
validate:
- {"check": "status_code", "comparator": "eq", "expect": 200}
- eq: ["status_code", $expect_status_code]
- {"check": "$token", "comparator": "len_eq", "expect": 16}
- len_eq: ["$token", $token_len]
- len_eq: ["content.token", 16]
- {"check": "status_code", "comparator": "eq", "expect": 200}
- {"check": "status_code", "comparator": "sum_status_code", "expect": 2}
- sum_status_code: ["status_code", 2]
- {"check": "$token", "comparator": "len_eq", "expect": 16}
- test:
name: create user which does not exist