Corrected integration tests

This commit is contained in:
Sergei Tsoganov 2023-08-04 12:46:56 +03:00
parent d150c1bc3d
commit b86fac03b5
3 changed files with 4 additions and 3 deletions

View file

@ -43,7 +43,7 @@ class ReppV1BaseTest < ActionDispatch::IntegrationTest
assert_equal 'Invalid authorization information', response_json[:message]
end
def test_takes_ip_whitelist_into_account
def test_takes_ip_whitelist_into_account_if_api_request
Setting.api_ip_whitelist_enabled = true
Setting.registrar_ip_whitelist_enabled = true
@ -67,7 +67,7 @@ class ReppV1BaseTest < ActionDispatch::IntegrationTest
Repp::V1::BaseController.stub_any_instance(:webclient_request?, true) do
Repp::V1::BaseController.stub_any_instance(:validate_webclient_ca, true) do
get repp_v1_contacts_path, headers: @auth_headers.merge!({ 'Request-IP' => whiteip.ipv4 })
get repp_v1_registrar_auth_index_path, headers: @auth_headers.merge!({ 'Request-IP' => whiteip.ipv4 })
end
end