summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorBob Halley <halley@dnspython.org>2014-08-31 17:14:05 -0700
committerBob Halley <halley@dnspython.org>2014-08-31 17:14:05 -0700
commite758ab4e7513f359e6deaf5725dcdd4ffa007d9a (patch)
treea728298bc9011ede88da74f05de234d30c1e286f /tests
parenteb195a787259c957c80355566512b4e9c5da5219 (diff)
downloaddnspython-e758ab4e7513f359e6deaf5725dcdd4ffa007d9a.tar.gz
Allow empty APL RR.
Diffstat (limited to 'tests')
-rw-r--r--tests/bugs.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/bugs.py b/tests/bugs.py
index 79b30eb..906e0fd 100644
--- a/tests/bugs.py
+++ b/tests/bugs.py
@@ -52,5 +52,13 @@ class BugsTestCase(unittest.TestCase):
out4 = rd4.to_digestable(dns.name.from_text("test"))
self.assertTrue(binascii.hexlify(out4).decode('ascii') == '000101817f')
+ def test_zero_size_APL(self):
+ rdata = dns.rdata.from_text(dns.rdataclass.IN, dns.rdatatype.APL,
+ "")
+ rdata2 = dns.rdata.from_wire(dns.rdataclass.IN, dns.rdatatype.APL,
+ b"", 0, 0)
+ self.assertTrue(rdata == rdata2)
+
+
if __name__ == '__main__':
unittest.main()