Browse Source

Remove existing tests with double dots

pull/1203/head
Ross McFarland 1 year ago
parent
commit
c5ea3c24d9
No known key found for this signature in database GPG Key ID: 943B179E15D3B22A
2 changed files with 7 additions and 2 deletions
  1. +6
    -2
      tests/test_octodns_processor_filter.py
  2. +1
    -0
      tests/test_octodns_record.py

+ 6
- 2
tests/test_octodns_processor_filter.py View File

@ -487,7 +487,9 @@ class TestZoneNameFilter(TestCase):
with_dot = zone.copy()
with_dot.add_record(
Record.new(
zone, zone.name, {'type': 'A', 'ttl': 43, 'value': '1.2.3.4'}
zone,
zone.name[:-1],
{'type': 'A', 'ttl': 43, 'value': '1.2.3.4'},
)
)
self.assertEqual(3, len(with_dot.records))
@ -514,7 +516,9 @@ class TestZoneNameFilter(TestCase):
zone = Zone('unit.tests.', [])
zone.add_record(
Record.new(
zone, zone.name, {'type': 'A', 'ttl': 43, 'value': '1.2.3.4'}
zone,
zone.name[:-1],
{'type': 'A', 'ttl': 43, 'value': '1.2.3.4'},
)
)
with self.assertRaises(ValidationError) as ctx:


+ 1
- 0
tests/test_octodns_record.py View File

@ -616,6 +616,7 @@ class TestRecordValidation(TestCase):
# should not raise with dots
name = 'xxxxxxxx.' * 10
name = name[:-1]
Record.new(
self.zone, name, {'ttl': 300, 'type': 'A', 'value': '1.2.3.4'}
)


Loading…
Cancel
Save