From: Tatiana Al-Chueyr Date: Thu, 24 Jul 2014 19:30:22 +0000 (-0700) Subject: Code cleanup with guided by @bdarnell at #1090 X-Git-Tag: v4.1.0b1~123^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b4aec6dd30a3196e819e34c20a89087adcc17cb7;p=thirdparty%2Ftornado.git Code cleanup with guided by @bdarnell at #1090 --- diff --git a/tornado/test/httpclient_test.py b/tornado/test/httpclient_test.py index 5e3454056..88b152ced 100644 --- a/tornado/test/httpclient_test.py +++ b/tornado/test/httpclient_test.py @@ -94,10 +94,7 @@ class ContentLength304Handler(RequestHandler): class PatchHandler(RequestHandler): def patch(self): - """ - Patch implementation according to RFC-6902 - http://tools.ietf.org/html/rfc6902 - """ + "Return the request payload - so we can check it is being kept" self.write(self.request.body) @@ -131,15 +128,6 @@ class HTTPClientCommonTestCase(AsyncHTTPTestCase): url('/patch', PatchHandler), ], gzip=True) - def fetch(self, path, body=None, **kwargs): - kwargs['url'] = self.get_url(path) - request = HTTPRequest(**kwargs) - if body is not None: - request.body = body - request.allow_nonstandard_methods = True - self.http_client.fetch(request, self.stop, method=None) - return self.wait() - def test_patch_receives_payload(self): body = b"some patch data" response = self.fetch("/patch", method='PATCH', body=body)