Update dependencies for newer Rails versions#39
Open
p8 wants to merge 4 commits into
Open
Conversation
::ActiveModel::Conversion requires the class_attribute method, which
isn't defined on Module:
NoMethodError:
undefined method 'class_attribute' for module Searchlight::Adapters::ActionView
By including it on the search_class we fix this error.
The ActionView::Base requires arguments for initializing in newer Rails
versions:
ArgumentError:
wrong number of arguments (given 0, expected 3)
Initialize it with with_empty_template_cache and with_view_paths just as
Rails does it:
https://github.com/rails/rails/blob/725c0a5812a61f84b44e352d2c9fc5c833471938/actionview/test/template/translation_helper_test.rb#L42-L44
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Initialize ActionView::Base in test with required arguments
The ActionView::Base requires arguments for initializing in newer Rails
versions:
Initialize it with with_empty_template_cache and with_view_paths just as
Rails does it:
https://github.com/rails/rails/blob/725c0a5812a61f84b44e352d2c9fc5c833471938/actionview/test/template/translation_helper_test.rb#L42-L44
Include ::ActiveModel::Conversion on search_class
::ActiveModel::Conversion requires the class_attribute method, which
isn't defined on Module:
By including it on the search_class we fix this error.
Fixes #36