Skip to content

Commit

Permalink
Add extra 'strict' key check (#275)
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelboulton authored and benhowes committed Feb 18, 2019
1 parent 7f54fec commit 34c6c8e
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions tests/integration/test_strict_key_checks.tavern.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -385,3 +385,47 @@ stages:
# an_integer: 123
a_string: abc
a_bool: true

---

test_name: Test strict key matching works for specific test stages with false

includes:
- !include common.yaml

stages:
- name: match with one key missing
request:
url: "{host}/fake_dictionary"
response:
status_code: 200
strict: False
body:
top:
Thing: value
an_integer: 123
a_string: abc
a_bool: true

---

test_name: Test strict key matching works for specific test stages with true

_xfail: run

includes:
- !include common.yaml

stages:
- name: match with one key missing
request:
url: "{host}/fake_dictionary"
response:
status_code: 200
strict: True
body:
top:
Thing: value
an_integer: 123
a_string: abc
a_bool: true

0 comments on commit 34c6c8e

Please sign in to comment.