From: Ben Darnell Date: Tue, 5 Jul 2011 07:12:30 +0000 (-0700) Subject: Use lists of tuples instead of dicts since this test cares about order X-Git-Tag: v2.1.0~110 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b9a68ee34442a15e6893586898e03cd2da8fc2ec;p=thirdparty%2Ftornado.git Use lists of tuples instead of dicts since this test cares about order --- diff --git a/tornado/test/httputil_test.py b/tornado/test/httputil_test.py index d73295958..8dd60c532 100644 --- a/tornado/test/httputil_test.py +++ b/tornado/test/httputil_test.py @@ -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")