From d7299404f3fabdfcf258fa648ed71d5b91da9f8f Mon Sep 17 00:00:00 2001 From: Alexander Griffen Date: Fri, 23 Jun 2023 14:05:49 +0100 Subject: [PATCH] style: Layout/LineLength RuboCop --- .../draft_info_request_batches.rb | 3 ++- .../request_summary_categories.rb | 5 ++-- spec/factories/info_requests.rb | 24 ++++++++++++------- spec/factories/post_redirects.rb | 5 +++- 4 files changed, 25 insertions(+), 12 deletions(-) diff --git a/spec/factories/alaveteli_pro/draft_info_request_batches.rb b/spec/factories/alaveteli_pro/draft_info_request_batches.rb index e34cac58b4..2c83eea364 100644 --- a/spec/factories/alaveteli_pro/draft_info_request_batches.rb +++ b/spec/factories/alaveteli_pro/draft_info_request_batches.rb @@ -13,7 +13,8 @@ # FactoryBot.define do - factory :draft_info_request_batch, class: AlaveteliPro::DraftInfoRequestBatch do + factory :draft_info_request_batch, + class: AlaveteliPro::DraftInfoRequestBatch do user sequence(:title) { |n| "Draft: Example Title #{n}" } sequence(:body) { |n| "Do you have information about record #{n}?" } diff --git a/spec/factories/alaveteli_pro/request_summary_categories.rb b/spec/factories/alaveteli_pro/request_summary_categories.rb index a96b64aa15..c80b8b1ca9 100644 --- a/spec/factories/alaveteli_pro/request_summary_categories.rb +++ b/spec/factories/alaveteli_pro/request_summary_categories.rb @@ -10,8 +10,9 @@ # FactoryBot.define do - factory :request_summary_category, class: 'AlaveteliPro::RequestSummaryCategory', - aliases: [:waiting_response_request_summary_category] do + factory :request_summary_category, + class: 'AlaveteliPro::RequestSummaryCategory', + aliases: [:waiting_response_request_summary_category] do slug { 'waiting_response' } end end diff --git a/spec/factories/info_requests.rb b/spec/factories/info_requests.rb index 93e58c69d8..3b56f4e397 100644 --- a/spec/factories/info_requests.rb +++ b/spec/factories/info_requests.rb @@ -165,7 +165,8 @@ trait :with_internal_review_request do after(:create) do |info_request, _evaluator| - outgoing_message = create(:internal_review_request, info_request: info_request) + outgoing_message = create(:internal_review_request, + info_request: info_request) end end @@ -273,7 +274,8 @@ end factory :info_request_with_incoming, traits: [:with_incoming] do - factory :waiting_clarification_info_request, traits: [:waiting_clarification] + factory :waiting_clarification_info_request, + traits: [:waiting_clarification] factory :successful_request, traits: [:successful] factory :requires_admin_request, traits: [:requires_admin] factory :error_message_request, traits: [:error_message] @@ -282,16 +284,22 @@ factory :not_held_request, traits: [:not_held] end - factory :info_request_with_plain_incoming, traits: [:with_plain_incoming] - factory :info_request_with_html_attachment, traits: [:with_incoming_with_html_attachment] - factory :info_request_with_pdf_attachment, traits: [:with_incoming_with_pdf_attachment] - factory :info_request_with_internal_review_request, traits: [:with_internal_review_request] - factory :embargoed_request, traits: [:embargoed, :with_incoming_with_pdf_attachment] + factory :info_request_with_plain_incoming, + traits: [:with_plain_incoming] + factory :info_request_with_html_attachment, + traits: [:with_incoming_with_html_attachment] + factory :info_request_with_pdf_attachment, + traits: [:with_incoming_with_pdf_attachment] + factory :info_request_with_internal_review_request, + traits: [:with_internal_review_request] + factory :embargoed_request, + traits: [:embargoed, :with_incoming_with_pdf_attachment] factory :embargo_expiring_request, traits: [:embargo_expiring] factory :re_embargoed_request, traits: [:re_embargoed] factory :embargo_expired_request, traits: [:embargo_expired] factory :external_request, traits: [:external] - factory :old_unclassified_request, traits: [:with_old_incoming, :awaiting_description] + factory :old_unclassified_request, + traits: [:with_old_incoming, :awaiting_description] factory :awaiting_description, traits: [:awaiting_description] factory :hidden_request, traits: [:hidden] factory :backpage_request, traits: [:backpage] diff --git a/spec/factories/post_redirects.rb b/spec/factories/post_redirects.rb index 2a06c0f8ff..7efd358ee0 100644 --- a/spec/factories/post_redirects.rb +++ b/spec/factories/post_redirects.rb @@ -33,7 +33,10 @@ public_body = FactoryBot.create(:public_body) { "outgoing_message" => { - "body" => "Dear Ministry of Defence,\r\n\r\nThis is my test\r\n\r\n\r\nYours faithfully,\r\n\r\nSteve Day", + "body" => "Dear Ministry of Defence,\r\n\r\n" \ + "This is my test\r\n\r\n\r\n" \ + "Yours faithfully,\r\n\r\n" \ + "Steve Day", "what_doing"=>"normal_sort" }, "info_request" => {