summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Lib/test/test_rfc822.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/Lib/test/test_rfc822.py b/Lib/test/test_rfc822.py
index 0bdd99afb3..c450bf97ce 100644
--- a/Lib/test/test_rfc822.py
+++ b/Lib/test/test_rfc822.py
@@ -222,6 +222,12 @@ A test message.
eq(rfc822.parseaddr('Cynthia Person <cperson@dom.ain>'),
('Cynthia Person', 'cperson@dom.ain'))
+ def test_quote_unquote(self):
+ eq = self.assertEqual
+ eq(rfc822.quote('foo\\wacky"name'), 'foo\\\\wacky\\"name')
+ eq(rfc822.unquote('"foo\\\\wacky\\"name"'), 'foo\\wacky"name')
+
+
def test_main():
test_support.run_unittest(MessageTestCase)