]> git.ipfire.org Git - thirdparty/tornado.git/commitdiff
Use lists of tuples instead of dicts since this test cares about order
authorBen Darnell <ben@bendarnell.com>
Tue, 5 Jul 2011 07:12:30 +0000 (00:12 -0700)
committerBen Darnell <ben@bendarnell.com>
Tue, 5 Jul 2011 07:12:30 +0000 (00:12 -0700)
tornado/test/httputil_test.py

index d73295958a5618d72a891df1e4ace60e4f82cf17..8dd60c5323017e69498b5a42b85f32383840d250 100644 (file)
@@ -9,48 +9,48 @@ class TestUrlConcat(unittest.TestCase):
     def test_url_concat_no_query_params(self):
         url = url_concat(
                 "https://localhost/path",
-                {'y':'y', 'z':'z'},
+                [('y','y'), ('z','z')],
                 )
         self.assertEqual(url, "https://localhost/path?y=y&z=z")
 
     def test_url_concat_encode_args(self):
         url = url_concat(
                 "https://localhost/path",
-                {'y':'/y', 'z':'z'},
+                [('y','/y'), ('z','z')],
                 )
         self.assertEqual(url, "https://localhost/path?y=%2Fy&z=z")
 
     def test_url_concat_trailing_q(self):
         url = url_concat(
                 "https://localhost/path?",
-                {'y':'y', 'z':'z'},
+                [('y','y'), ('z','z')],
                 )
         self.assertEqual(url, "https://localhost/path?y=y&z=z")
 
     def test_url_concat_q_with_no_trailing_amp(self):
         url = url_concat(
                 "https://localhost/path?x",
-                {'y':'y', 'z':'z'},
+                [('y','y'), ('z','z')],
                 )
         self.assertEqual(url, "https://localhost/path?x&y=y&z=z")
 
     def test_url_concat_trailing_amp(self):
         url = url_concat(
                 "https://localhost/path?x&",
-                {'y':'y', 'z':'z'},
+                [('y','y'), ('z','z')],
                 )
         self.assertEqual(url, "https://localhost/path?x&y=y&z=z")
 
     def test_url_concat_mult_params(self):
         url = url_concat(
                 "https://localhost/path?a=1&b=2",
-                {'y':'y', 'z':'z'},
+                [('y','y'), ('z','z')],
                 )
         self.assertEqual(url, "https://localhost/path?a=1&b=2&y=y&z=z")
 
     def test_url_concat_no_params(self):
         url = url_concat(
             "https://localhost/path?r=1&t=2",
-            {},
+            [],
             )
         self.assertEqual(url, "https://localhost/path?r=1&t=2")