Ejemplo n.º 1
0
 def do_add_record6(self, data):
     rec = AddressRecord(label = data['label'], domain=data['domain'], ip_str=data['ip'], ip_type='6')
     rec.save()
     self.assertTrue(rec.__repr__())
     self.assertTrue(rec.get_absolute_url())
     self.assertTrue(rec.get_edit_url())
     self.assertTrue(rec.get_delete_url())
     self.assertTrue(rec.details())
Ejemplo n.º 2
0
 def do_add_record6(self, data):
     rec = AddressRecord(label=data['label'],
                         domain=data['domain'],
                         ip_str=data['ip'],
                         ip_type='6')
     rec.save()
     self.assertTrue(rec.__repr__())
     self.assertTrue(rec.details())
Ejemplo n.º 3
0
    def do_add_record(self, data):
        rec = AddressRecord(label=data['label'], domain=data['domain'],
                            ip_str=data['ip'], ip_type='4')
        rec.save()
        self.assertTrue(rec.__repr__())
        self.assertTrue(rec.details())

        search = AddressRecord.objects.filter(label=data['label'],
                    domain=data['domain'], ip_type='4', ip_str=data['ip'])
        found = False
        for record in search:
            if record.ip_str == data['ip']:
                found = True
        self.assertTrue(found)
        return rec
Ejemplo n.º 4
0
    def do_add_record(self, data):
        rec = AddressRecord(label=data['label'],
                            domain=data['domain'],
                            ip_str=data['ip'],
                            ip_type='4')
        rec.save()
        self.assertTrue(rec.__repr__())
        self.assertTrue(rec.details())

        search = AddressRecord.objects.filter(label=data['label'],
                                              domain=data['domain'],
                                              ip_type='4',
                                              ip_str=data['ip'])
        found = False
        for record in search:
            if record.ip_str == data['ip']:
                found = True
        self.assertTrue(found)
        return rec