From 3af7b16c114802acdf0c0e7a34837a7a454fd23f Mon Sep 17 00:00:00 2001 From: Yves Senn Date: Fri, 12 Jul 2013 15:40:47 +0200 Subject: [PATCH] add test-case to verify `error.path` when a helper was not found. This verifies the code added with: https://github.com/rails/rails/commit/99c9d18601539c7e7e87f26bb047add1f93072af --- actionpack/test/abstract/helper_test.rb | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/actionpack/test/abstract/helper_test.rb b/actionpack/test/abstract/helper_test.rb index 8616e9837f..bc3e34684c 100644 --- a/actionpack/test/abstract/helper_test.rb +++ b/actionpack/test/abstract/helper_test.rb @@ -116,6 +116,11 @@ def test_controller_raise_error_about_missing_helper e = assert_raise(AbstractController::Helpers::MissingHelperError) { AbstractInvalidHelpers.helper(:missing) } assert_equal "Missing helper file helpers/missing_helper.rb", e.message end + + def test_missing_helper_error_has_the_right_path + e = assert_raise(AbstractController::Helpers::MissingHelperError) { AbstractInvalidHelpers.helper(:missing) } + assert_equal "helpers/missing_helper.rb", e.path + end end end end -- GitLab