Merge pull request #12667 from cyrillefr/FixRailsRootPathnameMethods

Fixes Rails/RootPathnameMethods offense
This commit is contained in:
Maikel
2024-08-06 11:02:28 +10:00
committed by GitHub
2 changed files with 1 additions and 7 deletions

View File

@@ -638,12 +638,6 @@ Rails/ResponseParsedBody:
- 'spec/controllers/spree/credit_cards_controller_spec.rb'
- 'spec/controllers/user_registrations_controller_spec.rb'
# Offense count: 1
# This cop supports unsafe autocorrection (--autocorrect-all).
Rails/RootPathnameMethods:
Exclude:
- 'spec/lib/reports/orders_and_fulfillment/order_cycle_customer_totals_report_spec.rb'
# Offense count: 7
# This cop supports unsafe autocorrection (--autocorrect-all).
# Configuration parameters: EnforcedStyle.

View File

@@ -35,7 +35,7 @@ RSpec.describe Reporting::Reports::OrdersAndFulfillment::OrderCycleCustomerTotal
end
end
let(:comparison_report) do
File.read(Rails.root.join(report_file_name))
Rails.root.join(report_file_name).read
end
let(:report_file_name) do
"spec/fixtures/reports/orders_and_fulfillment/order_cycle_customer_totals_report.csv"