Module: RESTful::Matchers
- Defined in:
- lib/restful/matchers/have_restful_json_link.rb
Defined Under Namespace
Classes: HaveRestfulJsonLink
Instance Method Summary collapse
-
#have_restful_json_link(rel, href = nil) ⇒ Object
(also: #have_link)
Ensures that JSON response body has the given link.
Instance Method Details
#have_restful_json_link(rel, href = nil) ⇒ Object Also known as: have_link
Ensures that JSON response body has the given link.
Example:
response.body.should have_json_link("self", "http://example.com")
10 11 12 |
# File 'lib/restful/matchers/have_restful_json_link.rb', line 10 def have_restful_json_link(rel, href = nil) HaveRestfulJsonLink.new(rel, href) end |