Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

added :prefixes accessor to LookupContext.

  • Loading branch information...
commit 37f448e05e411cb07e829a0d93f6a83ee95ccdf3 1 parent bff3740
@apotonick apotonick authored
View
2  actionpack/lib/action_view/lookup_context.rb
@@ -9,6 +9,8 @@ module ActionView
# generate a key, given to view paths, used in the resolver cache lookup. Since
# this key is generated just once during the request, it speeds up all cache accesses.
class LookupContext #:nodoc:
+ attr_accessor :prefixes
+
mattr_accessor :fallbacks
@@fallbacks = FallbackFileSystemResolver.instances
View
6 actionpack/test/template/lookup_context_test.rb
@@ -180,6 +180,12 @@ def teardown
assert_not_equal template, old_template
end
+
+ test "responds to #prefixes" do
+ assert_equal nil, @lookup_context.prefixes
+ @lookup_context.prefixes = ["foo"]
+ assert_equal ["foo"], @lookup_context.prefixes
+ end
end
class LookupContextWithFalseCaching < ActiveSupport::TestCase
Please sign in to comment.
Something went wrong with that request. Please try again.