summaryrefslogtreecommitdiff
path: root/spec/unit/network/http/api/v1_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/unit/network/http/api/v1_spec.rb')
-rwxr-xr-xspec/unit/network/http/api/v1_spec.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/unit/network/http/api/v1_spec.rb b/spec/unit/network/http/api/v1_spec.rb
index a952f24e2..039bccfd5 100755
--- a/spec/unit/network/http/api/v1_spec.rb
+++ b/spec/unit/network/http/api/v1_spec.rb
@@ -123,6 +123,10 @@ describe Puppet::Network::HTTP::API::V1 do
@tester.uri2indirection("GET", "/env/statuses/bar", {})[0].should == 'status'
end
+ it "should change indirection name to 'probe' if the http method is a GET and the indirection name is probes" do
+ @tester.uri2indirection("GET", "/env/probes/bar", {})[0].should == 'probe'
+ end
+
it "should choose 'delete' as the indirection method if the http method is a DELETE and the indirection name is singular" do
@tester.uri2indirection("DELETE", "/env/foo/bar", {})[1].should == :destroy
end