wsdsl 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/wsdsl.rb +2 -1
- data/spec/wsdsl_spec.rb +2 -0
- data/wsdsl.gemspec +1 -1
- metadata +2 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.3
|
data/lib/wsdsl.rb
CHANGED
@@ -125,7 +125,8 @@ class WSDSL
|
|
125
125
|
@response = WSDSL::Response.new
|
126
126
|
@name = extract_service_root_name(url)
|
127
127
|
if WSDSL.use_pluralized_controllers
|
128
|
-
|
128
|
+
base_name = ExtlibCopy::Inflection.pluralize(ExtlibCopy::Inflection.singular(name))
|
129
|
+
@controller_name = "#{ExtlibCopy.classify(base_name)}Controller"
|
129
130
|
else
|
130
131
|
@controller_name = "#{ExtlibCopy.classify(name)}Controller"
|
131
132
|
end
|
data/spec/wsdsl_spec.rb
CHANGED
@@ -79,6 +79,8 @@ describe WSDSL do
|
|
79
79
|
WSDSL.use_pluralized_controllers = true
|
80
80
|
service = WSDSL.new("player/:id.xml")
|
81
81
|
service.controller_name.should == "PlayersController"
|
82
|
+
service = WSDSL.new("players/:id.xml")
|
83
|
+
service.controller_name.should == "PlayersController"
|
82
84
|
WSDSL.use_pluralized_controllers = false
|
83
85
|
service = WSDSL.new("player/:id.xml")
|
84
86
|
service.controller_name.should == "PlayerController"
|
data/wsdsl.gemspec
CHANGED