Module: BeyondTheApiTestHelpers::Request::ShowAssertions
- Defined in:
- lib/beyond_the_api_test_helpers/request/show_assertions.rb
Instance Method Summary collapse
- #assert_request_show_not_found(urls_not_found, options = {}) ⇒ Object
- #assert_request_show_valid(url, options = {}) ⇒ Object
Instance Method Details
#assert_request_show_not_found(urls_not_found, options = {}) ⇒ Object
17 18 19 20 21 22 23 24 |
# File 'lib/beyond_the_api_test_helpers/request/show_assertions.rb', line 17 def assert_request_show_not_found(urls_not_found, = {}) request_instance_variables_set @headers.merge!(logged_in_headers) if required_login urls_not_found.each do |url_not_found| assert_request_show_not_found_i18n_all(url_not_found) end end |
#assert_request_show_valid(url, options = {}) ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 |
# File 'lib/beyond_the_api_test_helpers/request/show_assertions.rb', line 4 def assert_request_show_valid(url, = {}) request_instance_variables_set if required_login assert_request_needs_to_be_logged(url, :get) @headers.merge!(logged_in_headers) end get(url, params: @params, headers: @headers) response_assertions(status: 200) assert_kind_of Hash, json_response_name end |