Module: RSpecApi::Matchers::Status
- Included in:
- RSpecApi::Matchers
- Defined in:
- lib/rspec-api/matchers/status/matcher.rb,
lib/rspec-api/matchers/status/have_status.rb
Defined Under Namespace
Classes: Matcher
Instance Method Summary collapse
-
#have_status(status) ⇒ Object
Passes if the response has a status that matches
status
.
Instance Method Details
#have_status(status) ⇒ Object
Note:
The full list of symbolic HTTP status codes is available at: git.io/YwpDnA#L542
Passes if the response has a status that matches status
.
For more examples check have_headers_spec.rb
.
20 21 22 |
# File 'lib/rspec-api/matchers/status/have_status.rb', line 20 def have_status(status) RSpecApi::Matchers::Status::Matcher.new status end |