Add domain deleting support

This commit is contained in:
Martin Lensment 2014-09-01 11:48:24 +03:00
parent a9df2c82b1
commit 08a4650f4a
5 changed files with 40 additions and 11 deletions

View file

@ -439,6 +439,15 @@ describe 'EPP Domain', epp: true do
expect(d.owner_contact_code).to eq('mak21')
expect(d.auth_info).to eq('2BARfoo')
end
it 'does not delete domain if there are relations' do
expect(DomainContact.count).to eq(1)
response = epp_request('domains/delete.xml')
expect(response[:result_code]).to eq('1000')
expect(Domain.first).to eq(nil)
expect(DomainContact.count).to eq(0)
end
end
it 'checks a domain' do

View file

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<epp xmlns="urn:ietf:params:xml:ns:epp-1.0">
<command>
<delete>
<domain:delete
xmlns:domain="urn:ietf:params:xml:ns:domain-1.0">
<domain:name>example.ee</domain:name>
</domain:delete>
</delete>
<clTRID>ABC-12345</clTRID>
</command>
</epp>