diff options
| author | Rick Bradley <rick@rickbradley.com> | 2007-10-16 13:24:58 -0500 |
|---|---|---|
| committer | Rick Bradley <rick@rickbradley.com> | 2007-10-16 13:24:58 -0500 |
| commit | 6ab78f62ee589e542fd653a54109c0f5141ea026 (patch) | |
| tree | 0f601c90b4a73df4da87f3fd2f04acab5515585b /spec/unit/network/http/webrick | |
| parent | b8c877c121f6b376cd44b13cb90d69c41d0fb004 (diff) | |
| download | puppet-6ab78f62ee589e542fd653a54109c0f5141ea026.tar.gz puppet-6ab78f62ee589e542fd653a54109c0f5141ea026.tar.xz puppet-6ab78f62ee589e542fd653a54109c0f5141ea026.zip | |
Inlined the controller, eliminating a class. Mongrel+REST has the right bits for request handling prior to the encode/decode/exception-handling bits. Refactored to make the common logic extractable to a base class.
Diffstat (limited to 'spec/unit/network/http/webrick')
| -rw-r--r-- | spec/unit/network/http/webrick/rest.rb | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/spec/unit/network/http/webrick/rest.rb b/spec/unit/network/http/webrick/rest.rb index 70c50bf39..418c97b6f 100644 --- a/spec/unit/network/http/webrick/rest.rb +++ b/spec/unit/network/http/webrick/rest.rb @@ -50,11 +50,18 @@ end describe Puppet::Network::HTTP::WEBrickREST, "when receiving a request" do it "should unpack request information from WEBrick" + it "should unpack parameters from the request for passing to controller methods" + it "should call the controller find method if the request represents a singular HTTP GET" + it "should call the controller search method if the request represents a plural HTTP GET" + it "should call the controller destroy method if the request represents an HTTP DELETE" + it "should call the controller save method if the request represents an HTTP PUT" - it "should serialize the result from the controller method for return back to Mongrel" - it "should serialize a controller expection result for return back to Mongrel" + + it "should serialize the result from the controller method for return back to WEBrick" + + it "should serialize a controller exception result for return back to WEBrick" end |
