Open lostie opened 6 years ago
We have quite a lot of specs that require checking for the JSON output of an API.
This RSpec helpers should help us asserting more accurately the format and content of those outputs.
For example it allows us to use matchers inside the body, lets say for example if we're just interested in checking that we have a key foo with a value that is an Integer: https://relishapp.com/waterlink/rspec-json-expectations/docs/json-expectations/rspec-matcher-support-for-include-json-matcher
foo
@colinbruce @kmahern This is not a blocker for the ping issues PR, but could improve the assertions being made in the tests to assert both keys and values
we do already have this in the repo: https://github.com/collectiveidea/json_spec
We have quite a lot of specs that require checking for the JSON output of an API.
This RSpec helpers should help us asserting more accurately the format and content of those outputs.
For example it allows us to use matchers inside the body, lets say for example if we're just interested in checking that we have a key
foo
with a value that is an Integer: https://relishapp.com/waterlink/rspec-json-expectations/docs/json-expectations/rspec-matcher-support-for-include-json-matcher@colinbruce @kmahern This is not a blocker for the ping issues PR, but could improve the assertions being made in the tests to assert both keys and values