changeset 2544:bc49e37d2649

quoting tests for the parameter parser
author Johannes Berg <johannes AT sipsolutions DOT net>
date Mon, 23 Jul 2007 19:36:51 +0200
parents 116ab80df98b
children 3ef21e54f940
files MoinMoin/_tests/test_wikiutil.py
diffstat 1 files changed, 7 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/_tests/test_wikiutil.py	Mon Jul 23 19:36:38 2007 +0200
+++ b/MoinMoin/_tests/test_wikiutil.py	Mon Jul 23 19:36:51 2007 +0200
@@ -278,6 +278,13 @@
                   # trailing args
                   (u'1,2,a=b,3,4',            ([u'1', u'2'], {u'a': u'b'},
                                                [u'3', u'4'])),
+                  # can quote quotes:
+                  (u'd = """d"',              ([], {u'd': u'"d'}, [])),
+                  (u'd = """d"""',            ([], {u'd': u'"d"'}, [])),
+                  (u'd = "d"" ", e=7',        ([], {u'd': u'd" ', u'e': u'7'},
+                                               [])),
+                  (u'd = "d""", e=8',         ([], {u'd': u'd"', u'e': u'8'},
+                                               [])),
                 ]
         for args, expected in tests:
             result = wikiutil.parse_quoted_separated(args)