]> git.ipfire.org Git - thirdparty/tornado.git/commitdiff
Code cleanup with guided by @bdarnell at #1090
authorTatiana Al-Chueyr <tatiana.alchueyr@gmail.com>
Thu, 24 Jul 2014 19:30:22 +0000 (12:30 -0700)
committerTatiana Al-Chueyr <tatiana.alchueyr@gmail.com>
Thu, 24 Jul 2014 19:30:22 +0000 (12:30 -0700)
tornado/test/httpclient_test.py

index 5e3454056698c743f2a584a56753ffb0b8d73feb..88b152ced37df4c1c76b5963a86d2502e41bcc22 100644 (file)
@@ -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)