mirror of
https://github.com/internetee/registry.git
synced 2025-08-05 01:11:43 +02:00
Merge branch 'master' of github.com:domify/registry
This commit is contained in:
commit
a262e1e708
8 changed files with 45 additions and 16 deletions
|
@ -1993,6 +1993,21 @@ describe 'EPP Domain', epp: true do
|
|||
response[:results][0][:value].should == '4'
|
||||
end
|
||||
|
||||
it 'does not renew foreign domain' do
|
||||
login_as :registrar2 do
|
||||
exp_date = 1.year.since.to_date
|
||||
xml = @epp_xml.domain.renew(
|
||||
name: { value: domain.name },
|
||||
curExpDate: { value: exp_date.to_s },
|
||||
period: { value: '1', attrs: { unit: 'y' } }
|
||||
)
|
||||
|
||||
response = epp_plain_request(xml)
|
||||
response[:results][0][:msg].should == 'Authorization error'
|
||||
response[:results][0][:result_code].should == '2201'
|
||||
end
|
||||
end
|
||||
|
||||
### INFO ###
|
||||
it 'returns domain info' do
|
||||
domain.domain_statuses.build(value: DomainStatus::CLIENT_HOLD, description: 'Payment overdue.')
|
||||
|
|
|
@ -242,7 +242,7 @@ describe Domain do
|
|||
end
|
||||
|
||||
it 'should not be valid when name length is longer than 63 characters' do
|
||||
d = Fabricate.build(:domain,
|
||||
d = Fabricate.build(:domain,
|
||||
name: "xn--4caaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.ee")
|
||||
d.valid?
|
||||
d.errors.full_messages.should match_array([
|
||||
|
@ -294,6 +294,18 @@ describe Domain do
|
|||
d.errors.full_messages.should == ["Domain name Domain name is invalid"]
|
||||
end
|
||||
|
||||
it 'should not be valid with at character' do
|
||||
d = Fabricate.build(:domain, name: 'dass@sf.ee')
|
||||
d.valid?
|
||||
d.errors.full_messages.should == ["Domain name Domain name is invalid"]
|
||||
end
|
||||
|
||||
it 'should not be valid with invalid characters' do
|
||||
d = Fabricate.build(:domain, name: '@ba)s(?ä_:-df.ee')
|
||||
d.valid?
|
||||
d.errors.full_messages.should == ["Domain name Domain name is invalid"]
|
||||
end
|
||||
|
||||
it 'should be valid when name length is two pynicodes' do
|
||||
d = Fabricate.build(:domain, name: "xn--4caa.ee")
|
||||
d.valid?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue