From f800a02a429782bfcff0192268b6f8f63d86cdd2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javi=20Mart=C3=ADn?= Date: Thu, 25 Aug 2022 21:06:12 +0200 Subject: [PATCH] Add Layout/LineEndStringConcatenationIndentation rule This rule was added in Rubocop 1.18.0, but we didn't add it back then. Since we're applying it most of the time, we might as well be consistent and apply it everywhere. --- .rubocop.yml | 3 +++ db/dev_seeds/geozones.rb | 20 +++++++++---------- spec/system/admin/administrators_spec.rb | 2 +- .../system/admin/local_census_records_spec.rb | 2 +- spec/system/budgets/investments_spec.rb | 4 ++-- .../sdg_management/local_targets_spec.rb | 2 +- 6 files changed, 18 insertions(+), 15 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index 71f0bec9d..94b2b1a4e 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -66,6 +66,9 @@ Layout/IndentationWidth: Layout/LeadingEmptyLines: Enabled: true +Layout/LineEndStringConcatenationIndentation: + Enabled: true + Layout/LineLength: Max: 110 Severity: refactor diff --git a/db/dev_seeds/geozones.rb b/db/dev_seeds/geozones.rb index e8addbe35..98d75d137 100644 --- a/db/dev_seeds/geozones.rb +++ b/db/dev_seeds/geozones.rb @@ -2,23 +2,23 @@ section "Creating Geozones" do Geozone.create!(name: I18n.t("seeds.geozones.north_district"), external_code: "001", census_code: "01", html_map_coordinates: "30,139,45,153,77,148,107,165,138,201,146,218,186,198,216,"\ - "196,233,203,240,215,283,194,329,185,377,184,388,165,369,126,333,113,334,84,320,"\ - "66,286,73,258,65,265,57,249,47,207,58,159,84,108,85,72,101,51,114") + "196,233,203,240,215,283,194,329,185,377,184,388,165,369,126,333,113,334,84,320,"\ + "66,286,73,258,65,265,57,249,47,207,58,159,84,108,85,72,101,51,114") Geozone.create!(name: I18n.t("seeds.geozones.west_district"), external_code: "002", census_code: "02", html_map_coordinates: "42,153,31,176,24,202,20,221,44,235,59,249,55,320,30,354,"\ - "31,372,52,396,64,432,89,453,116,432,149,419,162,412,165,377,172,357,189,352,228,"\ - "327,246,313,262,297,234,291,210,284,193,284,176,294,158,303,154,310,146,289,140,"\ - "268,138,246,135,236,139,222,151,214,136,197,120,179,99,159,85,149,65,149,56,149") + "31,372,52,396,64,432,89,453,116,432,149,419,162,412,165,377,172,357,189,352,228,"\ + "327,246,313,262,297,234,291,210,284,193,284,176,294,158,303,154,310,146,289,140,"\ + "268,138,246,135,236,139,222,151,214,136,197,120,179,99,159,85,149,65,149,56,149") Geozone.create!(name: I18n.t("seeds.geozones.east_district"), external_code: "003", census_code: "03", html_map_coordinates: "175,353,162,378,161,407,153,416,167,432,184,447,225,426,"\ - "250,409,283,390,298,369,344,363,351,334,356,296,361,267,376,245,378,185,327,188,"\ - "281,195,239,216,245,221,245,232,261,244,281,238,300,242,304,251,285,262,278,277,"\ - "267,294,249,312,219,333,198,346,184,353") + "250,409,283,390,298,369,344,363,351,334,356,296,361,267,376,245,378,185,327,188,"\ + "281,195,239,216,245,221,245,232,261,244,281,238,300,242,304,251,285,262,278,277,"\ + "267,294,249,312,219,333,198,346,184,353") Geozone.create!(name: I18n.t("seeds.geozones.central_district"), external_code: "004", census_code: "04", html_map_coordinates: "152,308,137,258,133,235,147,216,152,214,186,194,210,196,"\ - "228,202,240,216,241,232,263,243,293,241,301,245,302,254,286,265,274,278,267,296,"\ - "243,293,226,289,209,285,195,283,177,297") + "228,202,240,216,241,232,263,243,293,241,301,245,302,254,286,265,274,278,267,296,"\ + "243,293,226,289,209,285,195,283,177,297") end diff --git a/spec/system/admin/administrators_spec.rb b/spec/system/admin/administrators_spec.rb index 3bca1971f..10f355938 100644 --- a/spec/system/admin/administrators_spec.rb +++ b/spec/system/admin/administrators_spec.rb @@ -36,7 +36,7 @@ describe "Admin administrators" do visit admin_administrators_path confirmation = "Are you sure? This action will delete "\ - "\"#{user_administrator.name}\" and can't be undone." + "\"#{user_administrator.name}\" and can't be undone." within "#administrator_#{user_administrator.id}" do accept_confirm(confirmation) { click_button "Delete" } diff --git a/spec/system/admin/local_census_records_spec.rb b/spec/system/admin/local_census_records_spec.rb index 1cc24feaf..cf30393b6 100644 --- a/spec/system/admin/local_census_records_spec.rb +++ b/spec/system/admin/local_census_records_spec.rb @@ -140,7 +140,7 @@ describe "Admin local census records", :admin do expect(page).to have_content deleted_document_number confirmation = "Are you sure? This action will delete "\ - "\"#{local_census_record.title}\" and can't be undone." + "\"#{local_census_record.title}\" and can't be undone." accept_confirm(confirmation) { click_on "Delete" } diff --git a/spec/system/budgets/investments_spec.rb b/spec/system/budgets/investments_spec.rb index ba3a20e22..0935d3d73 100644 --- a/spec/system/budgets/investments_spec.rb +++ b/spec/system/budgets/investments_spec.rb @@ -604,7 +604,7 @@ describe "Budget Investments" do fill_in_ckeditor "Description", with: "I want to live in a high tower over the clouds" fill_in "Location additional info", with: "City center" fill_in "If you are proposing in the name of a collective/organization, "\ - "or on behalf of more people, write its name", with: "T.I.A." + "or on behalf of more people, write its name", with: "T.I.A." fill_in "Tags", with: "Towers" check "I agree to the Privacy Policy and the Terms and conditions of use" @@ -669,7 +669,7 @@ describe "Budget Investments" do fill_in_ckeditor "Description", with: "I want to live in a high tower over the clouds" fill_in "Location additional info", with: "City center" fill_in "If you are proposing in the name of a collective/organization, "\ - "or on behalf of more people, write its name", with: "T.I.A." + "or on behalf of more people, write its name", with: "T.I.A." fill_in "Tags", with: "Towers" check "I agree to the Privacy Policy and the Terms and conditions of use" diff --git a/spec/system/sdg_management/local_targets_spec.rb b/spec/system/sdg_management/local_targets_spec.rb index 789f9c810..77d5e6065 100644 --- a/spec/system/sdg_management/local_targets_spec.rb +++ b/spec/system/sdg_management/local_targets_spec.rb @@ -90,7 +90,7 @@ describe "Local Targets" do visit sdg_management_local_targets_path confirmation = "Are you sure? This action will delete "\ - "\"#{sdg_local_target.title}\" and can't be undone." + "\"#{sdg_local_target.title}\" and can't be undone." accept_confirm(confirmation) { click_button "Delete" }