-
Notifications
You must be signed in to change notification settings - Fork 122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix deprecation warning (fixture_path -> fixture_paths) #1729
Fix deprecation warning (fixture_path -> fixture_paths) #1729
Conversation
@@ -76,7 +76,12 @@ def fixture_loader | |||
Class.new do | |||
T.unsafe(self).include(ActiveRecord::TestFixtures) | |||
|
|||
T.unsafe(self).fixture_path = Rails.root.join("test", "fixtures") | |||
if respond_to?(:fixture_paths=) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might be better to export and use a helper like
tapioca/lib/tapioca/helpers/test/template.rb
Lines 23 to 25 in c7b6c1e
def rails_version(selector) | |
::Gem::Requirement.new(selector).satisfied_by?(ActiveSupport.gem_version) | |
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added this, let me know what ya think.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay thanks!
|
a526fc8
to
3b5e246
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks. Existing tests should cover this compiler and we have CI for Rails 6.1 and main. Main isn't fully green but the relevant tests are passing.
Resolves:
Still need to add some tests!