Permalink
Browse files

Shouldn't use deprecated stuff

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4957 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
1 parent c810688 commit 9b18c1cb5768b0777b16bccdbfc3891a86af4558 Kent Sibilev committed Sep 3, 2006
View
2 actionwebservice/lib/action_web_service/templates/scaffolds/parameters.rhtml
@@ -6,7 +6,7 @@
<p>
<label for="protocol">Protocol:</label><br />
-<%= select_tag 'protocol', options_for_select([['SOAP', 'soap'], ['XML-RPC', 'xmlrpc']], @params['protocol']) %>
+<%= select_tag 'protocol', options_for_select([['SOAP', 'soap'], ['XML-RPC', 'xmlrpc']], params['protocol']) %>
</p>
<% if @scaffold_method.expects %>
View
2 actionwebservice/test/abstract_dispatcher.rb
@@ -208,7 +208,7 @@ def initialize
end
def add
- @added = @params['a'] + @params['b']
+ @added = params['a'] + params['b']
end
def add2(a, b)
View
10 actionwebservice/test/scaffolded_controller_test.rb
@@ -73,29 +73,29 @@ def setup
def test_scaffold_invoke
get :scaffold_invoke
- assert_rendered_file 'methods.rhtml'
+ assert_template 'methods.rhtml'
end
def test_scaffold_invoke_method_params
get :scaffold_invoke_method_params, :service => 'scaffolded', :method => 'Hello'
- assert_rendered_file 'parameters.rhtml'
+ assert_template 'parameters.rhtml'
end
def test_scaffold_invoke_method_params_with_struct
get :scaffold_invoke_method_params, :service => 'scaffolded', :method => 'HelloStructParam'
- assert_rendered_file 'parameters.rhtml'
+ assert_template 'parameters.rhtml'
assert_tag :tag => 'input', :attributes => {:name => "method_params[0][name]"}
end
def test_scaffold_invoke_submit_hello
post :scaffold_invoke_submit, :service => 'scaffolded', :method => 'Hello', :method_params => {'0' => '5', '1' => 'hello world'}
- assert_rendered_file 'result.rhtml'
+ assert_template 'result.rhtml'
assert_equal false, @controller.instance_eval{ @method_return_value }
end
def test_scaffold_invoke_submit_bye
post :scaffold_invoke_submit, :service => 'scaffolded', :method => 'Bye'
- assert_rendered_file 'result.rhtml'
+ assert_template 'result.rhtml'
persons = [ScaffoldPerson.new(:id => 1, :name => "leon"), ScaffoldPerson.new(:id => 2, :name => "paul")]
assert_equal persons, @controller.instance_eval{ @method_return_value }
end

0 comments on commit 9b18c1c

Please sign in to comment.