Class: ActionView::NullResolver

Inherits:
PathResolver show all
Defined in:
lib/action_view/testing/resolvers.rb

Constant Summary

Constants inherited from PathResolver

PathResolver::DEFAULT_PATTERN, PathResolver::EXTENSIONS

Instance Method Summary collapse

Methods inherited from PathResolver

#clear_cache, #initialize

Methods inherited from Resolver

#clear_cache, #find_all, #find_all_with_query, #initialize

Constructor Details

This class inherits a constructor from ActionView::PathResolver

Instance Method Details

#query(path, exts, _, locals, cache:) ⇒ Object



40
41
42
43
# File 'lib/action_view/testing/resolvers.rb', line 40

def query(path, exts, _, locals, cache:)
  handler, format, variant = extract_handler_and_format_and_variant(path)
  [ActionView::Template.new("Template generated by Null Resolver", path.virtual, handler, virtual_path: path.virtual, format: format, variant: variant, locals: locals)]
end