mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-05-18 13:38:24 -04:00
Rubocop: Rails/RedundantActiveRecordAllMethod
This commit is contained in:
@@ -614,7 +614,6 @@ Rails/RedundantActiveRecordAllMethod:
|
||||
- 'app/controllers/scientific_names_controller.rb'
|
||||
- 'spec/features/members/deletion_spec.rb'
|
||||
- 'spec/features/percy/percy_spec.rb'
|
||||
- 'spec/models/harvest_spec.rb'
|
||||
|
||||
# Offense count: 5
|
||||
# This cop supports unsafe autocorrection (--autocorrect-all).
|
||||
|
||||
@@ -144,7 +144,7 @@ describe Harvest do
|
||||
it 'lists most recent harvests first' do
|
||||
@h1 = create(:harvest, created_at: 1.day.ago)
|
||||
@h2 = create(:harvest, created_at: 1.hour.ago)
|
||||
expect(described_class.all.order(created_at: :desc)).to eq [@h2, @h1]
|
||||
expect(described_class.order(created_at: :desc)).to eq [@h2, @h1]
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user