domainname with only one character is now allowed

This commit is contained in:
2015-10-12 17:06:15 +02:00
parent 3aad913868
commit 15d94d5fff
5 changed files with 144 additions and 144 deletions

View File

@ -31,8 +31,8 @@ def test_domainname():
c.f = 'domainnametoolongthathavemorethanmaximumsizeforatruedomainnamea.nd'
c.f = 'domainnametoolongthathavemorethanmaximumsizeforatruedomainnamea.nditsnoteasytogeneratesolongdomainnamewithoutrepeatdomainnameto.olongthathavemorethanmaximumsizeforatruedomainnameanditsnoteas.ytogeneratesolongdomainnamewithoutrepeatbutimnotabletodoitnowie'
raises(ValueError, "c.f = 'domainnametoolongthathavemorethanmaximumsizeforatruedomainnamea.nditsnoteasytogeneratesolongdomainnamewithoutrepeatdomainnameto.olongthathavemorethanmaximumsizeforatruedomainnameanditsnoteas.ytogeneratesolongdomainnamewithoutrepeatbutimnotabletodoitnowien'")
raises(ValueError, "c.f = 'd'")
raises(ValueError, "c.f = 'd.t'")
c.f = 'd'
c.f = 'd.t'
#
c.g = 'toto.com'
c.g = '192.168.1.0'
@ -86,8 +86,8 @@ def test_domainname_warning():
c.f = 'domainnametoolongthathavemorethanmaximumsizeforatruedomainnamea.nd'
c.f = 'domainnametoolongthathavemorethanmaximumsizeforatruedomainnamea.nditsnoteasytogeneratesolongdomainnamewithoutrepeatdomainnameto.olongthathavemorethanmaximumsizeforatruedomainnameanditsnoteas.ytogeneratesolongdomainnamewithoutrepeatbutimnotabletodoitnowie'
raises(ValueError, "c.f = 'domainnametoolongthathavemorethanmaximumsizeforatruedomainnamea.nditsnoteasytogeneratesolongdomainnamewithoutrepeatdomainnameto.olongthathavemorethanmaximumsizeforatruedomainnameanditsnoteas.ytogeneratesolongdomainnamewithoutrepeatbutimnotabletodoitnowien'")
raises(ValueError, "c.f = 'd'")
raises(ValueError, "c.f = 'd.t'")
c.f = 'd'
c.f = 'd.t'
#
c.g = 'toto.com'
c.g = '192.168.1.0'