diff options
Diffstat (limited to 'test/integration')
-rw-r--r-- | test/integration/api/login_test.rb | 4 | ||||
-rw-r--r-- | test/integration/browser/account_livecycle_test.rb | 4 |
2 files changed, 5 insertions, 3 deletions
diff --git a/test/integration/api/login_test.rb b/test/integration/api/login_test.rb index 22047bc..97e0ff6 100644 --- a/test/integration/api/login_test.rb +++ b/test/integration/api/login_test.rb @@ -22,7 +22,7 @@ class LoginTest < SrpTest test "wrong password login attempt" do authenticate password: "wrong password" - assert_json_error "base" => "Not a valid username/password combination" + assert_json_error "base" => I18n.t(:invalid_user_pass) assert !last_response.successful? assert_nil server_auth["M2"] end @@ -31,7 +31,7 @@ class LoginTest < SrpTest assert_raises RECORD_NOT_FOUND do authenticate login: "wrong login" end - assert_json_error "base" => "Not a valid username/password combination" + assert_json_error "base" => I18n.t(:invalid_user_pass) assert !last_response.successful? assert_nil server_auth end diff --git a/test/integration/browser/account_livecycle_test.rb b/test/integration/browser/account_livecycle_test.rb index 694ff9c..cfab444 100644 --- a/test/integration/browser/account_livecycle_test.rb +++ b/test/integration/browser/account_livecycle_test.rb @@ -2,6 +2,8 @@ require 'test_helper' class AccountLivecycleTest < BrowserIntegrationTest + include ActionView::Helpers::SanitizeHelper + teardown do Identity.destroy_all_orphaned end @@ -115,7 +117,7 @@ class AccountLivecycleTest < BrowserIntegrationTest def assert_invalid_login(page) assert page.has_selector? '.btn-primary.disabled' - assert page.has_content? I18n.t(:invalid_user_pass) + assert page.has_content? sanitize(I18n.t(:invalid_user_pass), tags: []) assert page.has_no_selector? '.btn-primary.disabled' end |