mirror of
https://github.com/internetee/registry.git
synced 2025-08-04 00:42:04 +02:00
Renamed owner_contact to registrant
This commit is contained in:
parent
92f41ebe0b
commit
8cd3dcf551
21 changed files with 126 additions and 812 deletions
|
@ -326,13 +326,13 @@ describe Contact, '.destroy_orphans' do
|
|||
end
|
||||
|
||||
it 'should find one orphan' do
|
||||
Fabricate(:domain, owner_contact: @contact_1)
|
||||
Fabricate(:domain, registrant: @contact_1)
|
||||
Contact.find_orphans.count.should == 1
|
||||
Contact.find_orphans.last.should == @contact_2
|
||||
end
|
||||
|
||||
it 'should find no orphans' do
|
||||
Fabricate(:domain, owner_contact: @contact_1, admin_contacts: [@contact_2])
|
||||
Fabricate(:domain, registrant: @contact_1, admin_contacts: [@contact_2])
|
||||
cc = Contact.count
|
||||
Contact.find_orphans.count.should == 0
|
||||
Contact.destroy_orphans
|
||||
|
|
|
@ -7,7 +7,7 @@ describe Domain do
|
|||
|
||||
it { should belong_to(:registrar) }
|
||||
it { should have_many(:nameservers) }
|
||||
it { should belong_to(:owner_contact) }
|
||||
it { should belong_to(:registrant) }
|
||||
it { should have_many(:tech_contacts) }
|
||||
it { should have_many(:admin_contacts) }
|
||||
it { should have_many(:domain_transfers) }
|
||||
|
@ -156,7 +156,7 @@ describe Domain do
|
|||
# d = Domain.new
|
||||
# expect(d.valid?).to be false
|
||||
# expect(d.errors.messages).to match_array({
|
||||
# owner_contact: ['Registrant is missing'],
|
||||
# registrant: ['Registrant is missing'],
|
||||
# admin_contacts: ['Admin contacts count must be between 1 - infinity'],
|
||||
# nameservers: ['Nameservers count must be between 2-11'],
|
||||
# registrar: ['Registrar is missing'],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue