Skip to content
Myr

useragent

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

authored by Kenneth Reitz · committed by Kenneth Reitz · parent 3cdb777 · Browse files · 1 file+12 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+12 added−2 removed

  • other:+12 added−2 removed

1 file+12 added−2 removed

modified:test_requests.py+12 added-2 removed
42 unmodified lines
43 self.assertEqual(r.status_code, 200)4445 def test_user_agent_transfers(self):46 """Issue XX"""47 heads = {47 heads = {'User-agent':48 'Mozilla/5.0 (github.com/kennethreitz/requests)'}48 'User-agent':49 'Mozilla/5.0 (github.com/kennethreitz/requests)'50 }5152 r = requests.get('http://whatsmyua.com', headers=heads);53 self.assertTrue(heads['User-agent'] in r.content)5455 heads = {56 'user-agent':57 'Mozilla/5.0 (github.com/kennethreitz/requests)'58 }5960 r = requests.get('http://whatsmyua.com', headers=heads);61 self.assertTrue(heads['user-agent'] in r.content)6263 def test_HTTP_200_OK_HEAD(self):64 r = requests.head('http://google.com')65 self.assertEqual(r.status_code, 200)66
124 unmodified lines