mirror of
https://github.com/internetee/registry.git
synced 2025-07-23 03:06:14 +02:00
Validate uniqueness manually all the time
This commit is contained in:
parent
0ab1e29a53
commit
3f8f5cc4cd
5 changed files with 17 additions and 14 deletions
|
@ -19,6 +19,7 @@ describe 'EPP Domain', epp: true do
|
|||
Fabricate(:contact, code: 'jd1234')
|
||||
|
||||
response = epp_request(domain_create_xml, :xml)
|
||||
|
||||
expect(response[:results][0][:result_code]).to eq('2303')
|
||||
expect(response[:results][0][:msg]).to eq('Contact was not found')
|
||||
expect(response[:results][0][:value]).to eq('sh8013')
|
||||
|
@ -27,10 +28,6 @@ describe 'EPP Domain', epp: true do
|
|||
expect(response[:results][1][:msg]).to eq('Contact was not found')
|
||||
expect(response[:results][1][:value]).to eq('sh801333')
|
||||
|
||||
expect(response[:results][2][:result_code]).to eq('2303')
|
||||
expect(response[:results][2][:msg]).to eq('Contact was not found')
|
||||
expect(response[:results][2][:value]).to eq('sh8013')
|
||||
|
||||
expect(response[:clTRID]).to eq('ABC-12345')
|
||||
end
|
||||
|
||||
|
@ -456,15 +453,22 @@ describe 'EPP Domain', epp: true do
|
|||
expect(d.domain_statuses.last.value).to eq('clientUpdateProhibited')
|
||||
|
||||
response = epp_request(xml, :xml)
|
||||
|
||||
expect(response[:results][0][:result_code]).to eq('2302')
|
||||
expect(response[:results][0][:msg]).to eq('Contact already exists on this domain!')
|
||||
expect(response[:results][0][:value]).to eq('mak21')
|
||||
expect(response[:results][0][:msg]).to eq('Nameserver already exists on this domain')
|
||||
expect(response[:results][0][:value]).to eq('ns1.example.com')
|
||||
|
||||
expect(response[:results][1][:result_code]).to eq('2302')
|
||||
expect(response[:results][1][:msg]).to eq('Nameserver already exists on this domain')
|
||||
expect(response[:results][1][:value]).to eq('ns1.example.com')
|
||||
expect(response[:results][2][:msg]).to eq('Nameserver already exists on this domain')
|
||||
expect(response[:results][1][:value]).to eq('ns2.example.com')
|
||||
|
||||
expect(response[:results][2][:result_code]).to eq('2302')
|
||||
expect(response[:results][2][:msg]).to eq('Contact already exists on this domain!')
|
||||
expect(response[:results][2][:value]).to eq('mak21')
|
||||
|
||||
expect(response[:results][3][:msg]).to eq('Status already exists on this domain')
|
||||
expect(response[:results][3][:value]).to eq('clientHold')
|
||||
|
||||
expect(response[:results][4][:msg]).to eq('Status already exists on this domain')
|
||||
expect(response[:results][4][:value]).to eq('clientUpdateProhibited')
|
||||
expect(d.domain_statuses.count).to eq(2)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue