Skip to content
Myr

Fix tests on python 2.6

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Ian Cordasco · committed by Ian Cordasco · parent 767cc9d · Browse files · 1 file+4 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+4 added−2 removed

  • other:+4 added−2 removed

1 file+4 added−2 removed

modified:test_requests.py+4 added-2 removed
15 unmodified lines
16import pytest17from requests.adapters import HTTPAdapter18from requests.auth import HTTPDigestAuth, _basic_auth_str19from requests.compat import (20 Morsel, cookielib, getproxies, str, urljoin, urlparse, is_py3, builtin_str)20 Morsel, cookielib, getproxies, str, urljoin, urlparse, is_py3,21 builtin_str, OrderedDict22 )23from requests.cookies import cookiejar_from_dict, morsel_to_cookie24from requests.exceptions import (ConnectionError, ConnectTimeout,25 InvalidSchema, InvalidURL, MissingSchema,26 ReadTimeout, Timeout, RetryError)
100 unmodified lines
127 "http://example.com/path?key=value#fragment", params={"a": "b"}).prepare()128 assert request.url == "http://example.com/path?key=value&a=b#fragment"129130 def test_params_original_order_is_preserved_by_default(self):129 param_ordered_dict = collections.OrderedDict((('z', 1), ('a', 1), ('k', 1), ('d', 1)))131 param_ordered_dict = OrderedDict((('z', 1), ('a', 1), ('k', 1), ('d', 1)))132 session = requests.Session()133 request = requests.Request('GET', 'http://example.com/', params=param_ordered_dict)134 prep = session.prepare_request(request)135 assert prep.url == 'http://example.com/?z=1&a=1&k=1&d=1'
1533 unmodified lines