Add helper methods to stub and assert searches
Add helper methods to stub and assert searches

By not definining a default response (to_return) as part of the main stubbing method, this allows you to chain off `stub_any_rummager_search` to specify a suitable return value in your application’s tests.

You can use `stub_any_rummager_search_to_return_no_results` when you do not care about what Rummager will return.

Note that using stub_any_rummager_search _without_ chaining a call to `to_return` will probably result in errors as the Rummager class is expecting valid JSON to be returned.

alphagov/gds-api-adapters