Small fix for Python 2.6 compatibility.

Relates to #430 / #432.
This commit is contained in:
Michael Floering 2016-01-22 18:46:01 -06:00
parent 018e1f68de
commit deb7b747cc

View File

@ -19,7 +19,7 @@ class TestAuth:
requests.__version__ == '0.13.6',
reason='Redirects with prefetch=False are broken in Requests 0.13.6')
def test_digest_auth(self, httpbin, argument_name):
r = http('{}=digest'.format(argument_name), '--auth=user:password',
r = http(argument_name + '=digest', '--auth=user:password',
'GET', httpbin.url + '/digest-auth/auth/user/password')
assert HTTP_OK in r
assert r.json == {'authenticated': True, 'user': 'user'}