summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorBob Halley <halley@dnspython.org>2020-06-17 12:29:37 -0700
committerBob Halley <halley@dnspython.org>2020-06-17 12:30:25 -0700
commite8bed16c499d2f344d3f1c07bf0087b1a2e4eae2 (patch)
tree2d15719f035512b7efdcdd8b07628beab73431b1 /tests
parentd4dafd1bca84d1b5c12506fbd964aab14b5f33fa (diff)
downloaddnspython-e8bed16c499d2f344d3f1c07bf0087b1a2e4eae2.tar.gz
test bad class in zone
Diffstat (limited to 'tests')
-rw-r--r--tests/test_zone.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/test_zone.py b/tests/test_zone.py
index 62de3b4..6357890 100644
--- a/tests/test_zone.py
+++ b/tests/test_zone.py
@@ -695,6 +695,11 @@ class ZoneTestCase(unittest.TestCase):
dns.zone.from_text('foo 300 in a 10.0.0.1')
self.assertRaises(dns.zone.UnknownOrigin, bad)
+ def testBadClass(self):
+ def bad():
+ dns.zone.from_text('foo 300 ch txt hi', 'example.')
+ self.assertRaises(dns.exception.SyntaxError, bad)
+
def testDangling(self):
def bad1():
dns.zone.from_text('foo', 'example.')