diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index 1ce515947..2d239f006 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -210,17 +210,6 @@ Layout/AlignParameters: - 'spec/models/user_spec.rb' - 'spec/rails_helper.rb' -# Offense count: 1 -# Cop supports --auto-correct. -# Configuration parameters: EnforcedStyle, SupportedStyles, ProceduralMethods, FunctionalMethods, IgnoredMethods. -# SupportedStyles: line_count_based, semantic, braces_for_chaining -# ProceduralMethods: benchmark, bm, bmbm, create, each_with_object, measure, new, realtime, tap, with_object -# FunctionalMethods: let, let!, subject, watch -# IgnoredMethods: lambda, proc, it -Style/BlockDelimiters: - Exclude: - - 'spec/features/users_auth_spec.rb' - # Offense count: 2 # Cop supports --auto-correct. Layout/BlockEndNewline: diff --git a/spec/features/admin/poll/polls_spec.rb b/spec/features/admin/poll/polls_spec.rb index cb5a34265..d2041a583 100644 --- a/spec/features/admin/poll/polls_spec.rb +++ b/spec/features/admin/poll/polls_spec.rb @@ -248,18 +248,21 @@ feature 'Admin polls' do booth_assignment_recounted = create(:poll_booth_assignment, poll: poll) booth_assignment_final_recounted = create(:poll_booth_assignment, poll: poll) - 3.times { |i| create(:poll_recount, - booth_assignment: booth_assignment, - date: poll.starts_at + i.days, - count: 33) } + 3.times do |i| + create(:poll_recount, + booth_assignment: booth_assignment, + date: poll.starts_at + i.days, + count: 33) + end - 3.times { |i| create(:poll_final_recount, - booth_assignment: booth_assignment, - date: poll.starts_at + i.days, - count: 21) } + 3.times do |i| + create(:poll_final_recount, + booth_assignment: booth_assignment, + date: poll.starts_at + i.days, + count: 21) + end - 2.times { create(:poll_voter, - booth_assignment: booth_assignment_final_recounted) } + 2.times { create(:poll_voter, booth_assignment: booth_assignment_final_recounted) } create(:poll_recount, booth_assignment: booth_assignment_recounted, @@ -363,4 +366,4 @@ feature 'Admin polls' do end end -end \ No newline at end of file +end diff --git a/spec/features/budgets/investments_spec.rb b/spec/features/budgets/investments_spec.rb index b49fa8ddc..e131973da 100644 --- a/spec/features/budgets/investments_spec.rb +++ b/spec/features/budgets/investments_spec.rb @@ -337,14 +337,16 @@ feature 'Budget Investments' do end context "Show (feasible budget investment)" do - let(:investment) { create(:budget_investment, - :feasible, - :finished, - budget: budget, - group: group, - heading: heading, - price: 16, - price_explanation: 'Every wheel is 4 euros, so total is 16')} + let(:investment) do + create(:budget_investment, + :feasible, + :finished, + budget: budget, + group: group, + heading: heading, + price: 16, + price_explanation: 'Every wheel is 4 euros, so total is 16') + end background do user = create(:user) diff --git a/spec/features/officing/final_recount_spec.rb b/spec/features/officing/final_recount_spec.rb index 1fcfa48a1..ab1c39dc0 100644 --- a/spec/features/officing/final_recount_spec.rb +++ b/spec/features/officing/final_recount_spec.rb @@ -110,10 +110,12 @@ feature 'Officing Final Recount' do booth_assignment: final_officer_assignment.booth_assignment, date: 7.days.ago, count: 100) - 33.times { create(:poll_voter, :valid_document, - poll: poll, - booth_assignment: final_officer_assignment.booth_assignment, - created_at: final_recount.date) } + 33.times do + create(:poll_voter, :valid_document, + poll: poll, + booth_assignment: final_officer_assignment.booth_assignment, + created_at: final_recount.date) + end visit new_officing_poll_final_recount_path(poll) within("#poll_final_recount_#{final_recount.id}") do @@ -144,4 +146,4 @@ feature 'Officing Final Recount' do expect(page).to have_select('date', selected: I18n.l(final_recount.date.to_date, format: :long)) end -end \ No newline at end of file +end diff --git a/spec/features/users_auth_spec.rb b/spec/features/users_auth_spec.rb index 0e3d7b5e5..617b1b1d4 100644 --- a/spec/features/users_auth_spec.rb +++ b/spec/features/users_auth_spec.rb @@ -107,9 +107,17 @@ feature 'Users' do let(:twitter_hash){ {provider: 'twitter', uid: '12345', info: {name: 'manuela'}} } let(:twitter_hash_with_email){ {provider: 'twitter', uid: '12345', info: {name: 'manuela', email: 'manuelacarmena@example.com'}} } - let(:twitter_hash_with_verified_email){ {provider: 'twitter', - uid: '12345', - info: {name: 'manuela', email: 'manuelacarmena@example.com', verified: '1'}} } + let(:twitter_hash_with_verified_email) do + { + provider: 'twitter', + uid: '12345', + info: { + name: 'manuela', + email: 'manuelacarmena@example.com', + verified: '1' + } + } + end scenario 'Sign up when Oauth provider has a verified email' do OmniAuth.config.add_mock(:twitter, twitter_hash_with_verified_email)