diff options
author | Jeremy Hylton <jeremy@alum.mit.edu> | 2002-07-12 14:04:09 (GMT) |
---|---|---|
committer | Jeremy Hylton <jeremy@alum.mit.edu> | 2002-07-12 14:04:09 (GMT) |
commit | 39c03808c753457992dc931e1dd08a65e72a9a8f (patch) | |
tree | 9ddebc40369e5ca30862aa4df3b9fc13687375a3 /Lib/test/test_httplib.py | |
parent | dd523eef957bc1e4e1376dafde16b4dd81a3b9b7 (diff) | |
download | cpython-39c03808c753457992dc931e1dd08a65e72a9a8f.zip cpython-39c03808c753457992dc931e1dd08a65e72a9a8f.tar.gz cpython-39c03808c753457992dc931e1dd08a65e72a9a8f.tar.bz2 |
Change _begin() back to begin().
Client code could create responses explicitly.
Diffstat (limited to 'Lib/test/test_httplib.py')
-rw-r--r-- | Lib/test/test_httplib.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/test/test_httplib.py b/Lib/test/test_httplib.py index 1edb062..09f92fc 100644 --- a/Lib/test/test_httplib.py +++ b/Lib/test/test_httplib.py @@ -16,7 +16,7 @@ class FakeSocket: body = "HTTP/1.1 200 Ok\r\n\r\nText" sock = FakeSocket(body) resp = httplib.HTTPResponse(sock, 1) -resp._begin() +resp.begin() print resp.read() resp.close() @@ -24,7 +24,7 @@ body = "HTTP/1.1 400.100 Not Ok\r\n\r\nText" sock = FakeSocket(body) resp = httplib.HTTPResponse(sock, 1) try: - resp._begin() + resp.begin() except httplib.BadStatusLine: print "BadStatusLine raised as expected" else: @@ -52,7 +52,7 @@ hdr = ('Customer="WILE_E_COYOTE"; Version="1"; Path="/acme"' 'Part_Number="Rocket_Launcher_0001"; Version="1"; Path="/acme"') s = FakeSocket(text) r = httplib.HTTPResponse(s, 1) -r._begin() +r.begin() cookies = r.getheader("Set-Cookie") if cookies != hdr: raise AssertionError, "multiple headers not combined properly" |