mirror of
https://github.com/internetee/registry.git
synced 2025-06-10 14:44:47 +02:00
Merge branch 'registry-707' into registry-694
This commit is contained in:
commit
fafb224c00
8 changed files with 53 additions and 4 deletions
28
test/integration/epp/domain/domain_delete_test.rb
Normal file
28
test/integration/epp/domain/domain_delete_test.rb
Normal file
|
@ -0,0 +1,28 @@
|
|||
require 'test_helper'
|
||||
|
||||
class EppDomainDeleteTest < ActionDispatch::IntegrationTest
|
||||
def test_bypasses_domain_and_registrant_and_contacts_validation
|
||||
request_xml = <<-XML
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<epp xmlns="https://epp.tld.ee/schema/epp-ee-1.0.xsd">
|
||||
<command>
|
||||
<delete>
|
||||
<domain:delete xmlns:domain="https://epp.tld.ee/schema/domain-eis-1.0.xsd">
|
||||
<domain:name>invalid.test</domain:name>
|
||||
</domain:delete>
|
||||
</delete>
|
||||
<extension>
|
||||
<eis:extdata xmlns:eis="https://epp.tld.ee/schema/eis-1.0.xsd">
|
||||
<eis:legalDocument type="pdf">dGVzdCBmYWlsCg==</eis:legalDocument>
|
||||
</eis:extdata>
|
||||
</extension>
|
||||
</command>
|
||||
</epp>
|
||||
XML
|
||||
|
||||
post '/epp/command/delete', { frame: request_xml }, { 'HTTP_COOKIE' => 'session=api_bestnames' }
|
||||
assert_includes Domain.find_by(name: 'invalid.test').statuses, DomainStatus::PENDING_DELETE_CONFIRMATION
|
||||
assert_equal '1001', Nokogiri::XML(response.body).at_css('result')[:code]
|
||||
assert_equal 1, Nokogiri::XML(response.body).css('result').size
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue