From 163152bfd0ea5344472d24b6f89e8c957dbd66f5 Mon Sep 17 00:00:00 2001 From: David Chelimsky Date: Tue, 25 May 2010 00:34:55 -0500 Subject: Support configuration of controller.controller_path on instances of ActionView::TestCase::TestController without stubs. Just say: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit @controller.controller_path = "path/i/need/for/this/test" [#4697 state:resolved] Signed-off-by: José Valim --- actionpack/test/template/test_case_test.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'actionpack/test/template/test_case_test.rb') diff --git a/actionpack/test/template/test_case_test.rb b/actionpack/test/template/test_case_test.rb index a4fb9f22bf..25dbc04ce1 100644 --- a/actionpack/test/template/test_case_test.rb +++ b/actionpack/test/template/test_case_test.rb @@ -112,7 +112,7 @@ module ActionView end end - TestController.stubs(:controller_path).returns('test') + @controller.controller_path = 'test' @customers = [stub(:name => 'Eloy'), stub(:name => 'Manfred')] assert_match /Hello: EloyHello: Manfred/, render(:partial => 'test/from_helper') @@ -161,7 +161,7 @@ module ActionView end test "is able to render partials from templates and also use instance variables" do - TestController.stubs(:controller_path).returns('test') + @controller.controller_path = "test" @customers = [stub(:name => 'Eloy'), stub(:name => 'Manfred')] assert_match /Hello: EloyHello: Manfred/, render(:file => 'test/list') -- cgit v1.2.3