Namespace
Methods
- S
- T
- W
Included Modules
Instance Public methods
Source: show
# File rails/actionpack/test/template/url_helper_test.rb, line 335 def setup @request = ActionController::TestRequest.new @response = ActionController::TestResponse.new @controller = TasksController.new end
Source: show
# File rails/actionpack/test/template/url_helper_test.rb, line 348 def test_link_to_unless_current_shows_link with_restful_routing do get :show, :id => 1 assert_equal "<a href=\"/tasks\">tasks</a>\n" + "<a href=\"#{@request.protocol}#{@request.host_with_port}/tasks\">tasks</a>", @response.body end end
Source: show
# File rails/actionpack/test/template/url_helper_test.rb, line 341 def test_link_to_unless_current_to_current with_restful_routing do get :index assert_equal "tasks\ntasks", @response.body end end
Instance Protected methods
Source: show
# File rails/actionpack/test/template/url_helper_test.rb, line 358 def with_restful_routing with_routing do |set| set.draw do |map| map.resources :tasks end yield end end