ilanap | 637206b | 2018-02-04 17:06:22 +0200 | [diff] [blame] | 1 | Feature: Example for checking response data |
| 2 | Scenario: Example Checks |
| 3 | # setting some data just for testing purposes |
| 4 | Given Response Data: |
| 5 | """ |
| 6 | { |
| 7 | "field1" : "string field", |
| 8 | "field2" : "true", |
| 9 | "field3": "5", |
| 10 | "field4" : [{"entry1":"a"},{"entry2":"b"},{"entry3":"c"}] |
| 11 | } |
| 12 | """ |
| 13 | # printing out for test purposes |
| 14 | Then I want to print the context data |
| 15 | |
| 16 | # running the different options of checking the respone data |
| 17 | Then I want to check property "field1" for value "string field" |
| 18 | Then I want to check property "field2" to be "true" |
| 19 | Then I want to check property "field3" for value 5 |
| 20 | Then I want to check property "field4" to have length 3 |
| 21 | Then I want to check property "field4[0].entry1" exists |
| 22 | Then I want to check property "field4[0].no_exist" does not exist |