mirror of
https://github.com/internetee/registry.git
synced 2025-05-16 17:37:17 +02:00
Add test for updating domain pw #2833
This commit is contained in:
parent
3c934d70e8
commit
8b5428fa3b
2 changed files with 18 additions and 1 deletions
|
@ -1,4 +1,4 @@
|
|||
TEST_EMAILS =
|
||||
TEST_EMAILS =
|
||||
if Rails.env.test?
|
||||
%w(
|
||||
test@example.com
|
||||
|
@ -9,5 +9,6 @@ TEST_EMAILS =
|
|||
new@example.com
|
||||
)
|
||||
else
|
||||
ENV['whitelist_emails_for_staging'] ||= ''
|
||||
ENV['whitelist_emails_for_staging'].split(',').map(&:strip)
|
||||
end
|
||||
|
|
|
@ -1819,6 +1819,22 @@ describe 'EPP Domain', epp: true do
|
|||
d.pending_update?.should == true
|
||||
end
|
||||
|
||||
it 'updates a domain and changes auth info' do
|
||||
response = epp_plain_request(domain_update_xml({
|
||||
name: { value: domain.name },
|
||||
chg: [
|
||||
authInfo: { pw: { value: 'newpw' } }
|
||||
]
|
||||
}))
|
||||
|
||||
response[:results][0][:msg].should == 'Command completed successfully'
|
||||
response[:results][0][:result_code].should == '1000'
|
||||
|
||||
d = Domain.last
|
||||
|
||||
d.auth_info.should == 'newpw'
|
||||
end
|
||||
|
||||
it 'should not return action pending when changes are invalid' do
|
||||
existing_pw = domain.auth_info
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue