pvl/hosts/tests.py
changeset 467 3bb00e5e79d3
parent 466 ad9d512ec1e7
child 468 3e7cb8dd5708
equal deleted inserted replaced
466:ad9d512ec1e7 467:3bb00e5e79d3
   153             ('host', 'A'): ['192.0.2.1'],
   153             ('host', 'A'): ['192.0.2.1'],
   154             ('test', 'CNAME'): ['host'],
   154             ('test', 'CNAME'): ['host'],
   155             ('*.test', 'CNAME'): ['host'],
   155             ('*.test', 'CNAME'): ['host'],
   156         })
   156         })
   157 
   157 
   158     # TODO: forward=... with alias=
   158     def testHostForwardAlias(self):
       
   159         h = host.Host.build('host', 'domain',
       
   160                 forward = 'host.example.net',
       
   161                 alias   = 'test',
       
   162         )
       
   163 
       
   164         self.assertZoneEquals(zone.host_forward(h, 'domain'), {
       
   165             ('host', 'CNAME'): ['host.example.net.'],
       
   166             ('test', 'CNAME'): ['host'],
       
   167         })
   159 
   168 
   160     def testHostDelegateForward(self):
   169     def testHostDelegateForward(self):
   161         h = host.Host.build('host', 'example.com',
   170         h = host.Host.build('host', 'example.com',
   162                 forward = 'host.example.net',
   171                 forward = 'host.example.net',
   163         )
   172         )