Download Install Tutorial Docs FAQ Tools WikiLicense Team IRC Planet Involvement Shop Book

Changeset 1607

Show
Ignore:
Timestamp:
01/31/07 18:46:24
Author:
fumanchu
Message:

Better test for #650.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/cherrypy/test/test_core.py

    r1606 r1607  
    341341            # which CP will just pipe back out if we tell it to. 
    342342            return cherrypy.request.body 
     343         
     344        def reachable(self): 
     345            return "success" 
    343346 
    344347    class Divorce: 
     
    898901        self.assertBody(b) 
    899902         
    900         # Request a PUT method with an empty body
     903        # Request a PUT method with no body whatsoever (not an empty one)
    901904        # See http://www.cherrypy.org/ticket/650. 
    902         h = [("Content-Type", "text/plain"), 
    903              ("Content-Length", "0")] 
    904         self.getPage("/method/request_body", headers=h, method="PUT", body="") 
    905         self.assertBody("") 
     905        # Provide a C-T or webtest will provide one (and a C-L) for us. 
     906        h = [("Content-Type", "text/plain")] 
     907        self.getPage("/method/reachable", headers=h, method="PUT") 
     908        self.assertBody("success") 
    906909         
    907910        # Request a custom method with a request body 

Hosted by WebFaction

Log in as guest/cpguest to create tickets