Commits

Robert Brewer committed fd60630

3.0 test for #650 (PUT request with empty body/params ignored).

Comments (0)

Files changed (1)

cherrypy/test/test_core.py

         self.assertStatus(200)
         self.assertBody(b)
         
+        # Request a PUT method with an empty body.
+        # See http://www.cherrypy.org/ticket/650.
+        h = [("Content-Type", "text/plain"),
+             ("Content-Length", "0")]
+        self.getPage("/method/request_body", headers=h, method="PUT", body="")
+        self.assertBody("")
+        
         # Request a custom method with a request body
         b = ('<?xml version="1.0" encoding="utf-8" ?>\n\n'
              '<propfind xmlns="DAV:"><prop><getlastmodified/>'