imbo / behat-api-extension

API extension for Behat, used to ease testing of JSON-based APIs
MIT License
109 stars 42 forks source link

Verify response value types #41

Closed oqq closed 7 years ago

oqq commented 7 years ago

Currently there is no way to test the type from a json value.

Given the following response body

{
        "timed_out": false,
        "amount": 15,
        "max_score": 0.15367,
        "items": []
}

Would like it where viable to test

christeredvartsen commented 7 years ago

Added to the newly created v2.0 milestone. When other tasks have been done I can come up with a suggestion to an implementation for this.

First thought is to add some sort of callback (like @length for instance) called @type or something similar.

christeredvartsen commented 7 years ago

Closed by commits from #42.