kennethreitz
d8557a2627
Merge pull request #1935 from cjstapleton/master
...
Add timeout to stream with testing
2014-03-03 13:14:37 -05:00
cjstapleton
5f404a0592
Fix styling issues with add timeout to stream with testing
2014-02-28 19:06:59 -06:00
cjstapleton
930f03c864
Add timeout to stream with testing
...
Fixes Issue #1803
2014-02-28 10:08:57 -06:00
Ian Cordasco
d2f647cee4
Do not set headers with None value
...
- Regardless of whether they are on the session or not
- Fixes #1920
2014-02-14 16:15:21 -06:00
Zack Weinberg
0caa243212
New Response property, .is_redirect.
2014-02-13 14:27:42 -05:00
Konstantinos Koukopoulos
b6e16799d0
test pyopenssl redirect (unit test for #1887 )
2014-01-28 09:08:16 -08:00
Roberto Migli
eb124353af
Added comment for test test_get_auth_from_url
2014-01-13 16:29:46 +01:00
Roberto Migli
49fb630eb4
Merged changes from @lukasa
2014-01-13 14:04:28 +01:00
Roberto Migli
a6a8342066
Fixed parsing of username and password encoded in the URI
2014-01-13 13:32:00 +01:00
Cory Benfield
ca187abd13
Unquote the auth after splitting the url.
2014-01-11 09:59:23 +00:00
Konstantin Podshumok
b8f1263f16
split cookiejar as dict test
2013-12-18 18:50:53 +04:00
Konstantin Podshumok
e6a32d6283
preserve python2-like dict API for RequestCookieJar
2013-12-18 18:09:24 +04:00
Konstantin Podshumok
537def4a4f
fix regression with cookiejar.iteritems()
2013-12-18 06:56:53 +04:00
Michael Becker
837ba94dde
test_requests: convert tests to py.test style
2013-12-06 10:08:42 -05:00
Michael Becker
ea4570da57
cookies: Fix bugs found during CI
2013-12-06 09:02:45 -05:00
Michael Becker
ef5875cc19
cookies: Take a less cowardly approach
...
Per discussion with @sigmavirus24, we'll take the less cowardly approach here.
"the RFC defines the Expires header as a string with the format we're assigning to ``time_template`` so checking if it is a string is unnecessary."
Crossing my fingers that this doesn't break anyones existing code...
2013-12-06 09:02:45 -05:00
Michael Becker
39841562c5
test_requests: Add tests for morsel_to_cookie
...
These tests will ensure my changes to how we handle 'expires' don't cause any regressions.
2013-12-06 08:56:30 -05:00
kennethreitz
ba3dab5047
Merge pull request #1770 from kmadac/master
...
Implemetation of IP address ranges for no_proxy environment variable
2013-12-05 14:40:44 -08:00
Kamil Madac
1d42d9d274
function is_ipv4_network renamed
...
more detailed check of cidr format
2013-12-05 11:15:52 +01:00
Kamil Madac
0d52ef7084
Additional tests added
2013-12-04 15:10:24 +01:00
Chase Sterling
5b30e960eb
Add a test case for request cookies persisting to session. refs #1728
2013-12-04 06:35:16 -06:00
Kamil Madac
0a4e65c0ed
Tests added
2013-12-04 10:54:36 +01:00
kennethreitz
4bceb312f1
Merge pull request #1768 from Lukasa/credpct
...
Unencode usernames and passwords taken from URLs.
2013-12-03 17:36:00 -08:00
kennethreitz
a030a58303
Merge pull request #1766 from Lukasa/qop
...
Quote qop values in digest auth.
2013-12-03 17:33:59 -08:00
kennethreitz
5c915451e7
Merge pull request #1657 from sigmavirus24/fix-session-hooks
...
Honor session hooks
2013-12-03 17:33:42 -08:00
Kamil Madac
6131390345
Revert "Small test added"
...
This reverts commit f0d3edf409 .
2013-12-03 16:41:07 +01:00
Kamil Madac
f0d3edf409
Small test added
2013-12-03 16:30:47 +01:00
Kamil Madac
8aff6f5ed0
Redesigned no_proxy ip range imlementation to use only stdlib functions
2013-12-03 16:23:08 +01:00
Kamil Madac
2c914126ba
Added possibility to use IP ranges (ex. 192.168.1.0/24) to no_proxy environment variable
2013-12-02 22:32:29 +01:00
Cory Benfield
4f786e4f62
Tests for #1767 .
2013-12-01 10:29:10 +00:00
Cory Benfield
fecb35a08e
Quote qop values in digest auth.
2013-11-29 08:37:25 +00:00
daftshady
5fcaf45c33
update 'merge_cookies' not to create new instance.
2013-11-26 15:28:59 +09:00
daftshady
1adba3c9e9
modified 'merge_cookies' and update tests.
...
made sessions.py to use that method when merging cookies.
2013-11-26 15:28:59 +09:00
daftshady
e3c771f36b
added test case related to #1711
2013-11-26 15:22:46 +09:00
kennethreitz
af921c7f51
Merge pull request #1733 from ionrock/pickleable-responses
...
Response and Request objects are pickleable.
2013-11-20 01:01:26 -08:00
Jayson Vantuyl
b149be5d86
loosen URL handling for non-native URL schemes
2013-11-15 01:25:32 -08:00
Eric Larson
512beb8795
Response and Request objects are pickleable.
...
Includes a basic test. More could be add to confirm known attributes
that could cause problems.
2013-11-06 20:01:27 -06:00
daftshady
1511dfa637
moved logic to Session object and added test case
2013-11-04 22:32:17 +09:00
Kenneth Reitz
0228851f19
Revert "Merge pull request #1710 from jvantuyl/master"
...
This reverts commit a8300c0ae6 , reversing
changes made to 2e196be143 .
2013-10-30 15:32:19 -04:00
Jayson Vantuyl
a9ec28a1b4
don't prepare URLs for oddball schemes
2013-10-30 10:04:43 -07:00
Can Ibanoglu
aa60b8ea5b
Modified the tests so that they use py.test convention
2013-10-26 13:38:11 +03:00
Cory Benfield
8a42d5fb41
Use builtin_str for all auto-set header values.
2013-10-18 18:34:29 +01:00
Matt Spitz
13a6e02ccd
Increasing super_len compatibilty to include BytesIO and cStringIO objects.
...
Added a check for 'getvalue' attr, calling it to retrieve the length if we can.
We also try/except the fileno() call, which can throw
io.UnsupportedOperation for BytesIO because, well, they're not files.
2013-10-10 14:54:47 -04:00
Ian Cordasco
f12584b94a
Add tests around hook behaviour
2013-10-07 21:17:46 -05:00
daftshady
39fe0068aa
Fixed #1630 , added test case for cookie persistence.
2013-09-28 16:33:05 +09:00
Kenneth Reitz
54ad646067
merge 2.0 insto master
2013-09-24 14:13:28 -04:00
Kenneth Reitz
23ced527f7
Merge pull request #1503 from skastel/master
...
Fixing error return to be consistent with tuple return at the end of the method
2013-09-24 10:48:07 -07:00
Jon Parise
b9b5be7c4c
Improved content encoding detection.
...
get_encodings_from_content() can now detect HTML in-document content
encoding declarations in the following formats:
- HTML5
- HTML4
- XHTML 1.x served with text/html MIME type
- XHTML 1.x served as XML
Ref: http://www.w3.org/International/questions/qa-html-encoding-declarations
2013-09-03 16:16:46 -07:00
Cory Benfield
f44b86e039
Allow non-string objects to be data with files
2013-08-17 07:27:58 +01:00
Stephen Huenneke
b676bf3214
Fixing tests to verify thrown ValueError's.
2013-08-08 09:20:41 -07:00