]> git.ipfire.org Git - thirdparty/dnspython.git/commitdiff
Use meaningful test 177/head
authorCasey Deccio <casey@deccio.net>
Sat, 25 Jun 2016 00:44:29 +0000 (20:44 -0400)
committerCasey Deccio <casey@deccio.net>
Sat, 25 Jun 2016 00:44:29 +0000 (20:44 -0400)
Test added in 257f2a didn't actually test the problem addressed in
257f2a.  This one does.

tests/test_name.py

index 645cf75918c9070280abcf2fff6f0cffb9aa7820..e4ff9e8aca2f2488d24f6037276e2887f880410c 100644 (file)
@@ -238,9 +238,9 @@ class NameTestCase(unittest.TestCase):
         self.assertEqual(t, b'FOO\.bar')
 
     def testToText9(self):
-        n = dns.name.from_text(r'\x80\.bar', origin=None)
-        t = n.to_text()
-        self.assertEqual(t, br'x80\.bar')
+        n = dns.name.from_text('FOO bar', origin=None)
+        t = n.to_unicode()
+        self.assertEqual(t, r'FOO\032bar')
 
     def testSlice1(self):
         n = dns.name.from_text(r'a.b.c.', origin=None)