Let registrar users change registrar account

This commit is contained in:
Artur Beljajev 2019-05-15 14:29:20 +03:00
parent 207c2a704c
commit 37249a24f7
8 changed files with 104 additions and 9 deletions

View file

@ -0,0 +1,22 @@
require 'test_helper'
class RegistrarAccountTest < ApplicationSystemTestCase
setup do
@registrar = registrars(:bestnames)
sign_in users(:api_bestnames)
end
def test_updates_account
new_billing_email = 'new@registrar.test'
assert_not_equal new_billing_email, @registrar.billing_email
visit registrar_account_path
click_on 'Edit'
fill_in 'Billing email', with: new_billing_email
click_on 'Save changes'
assert_text 'Your account has been updated'
assert_text new_billing_email
end
end