Fix all Layout/SpaceAfterComma issues and remove from rubocop_todo list

This commit is contained in:
Bertocq
2017-06-21 22:37:06 +02:00
parent c862543e6f
commit e6dd33bd66
15 changed files with 17 additions and 32 deletions

View File

@@ -356,7 +356,7 @@ feature 'Admin polls' do
question_2.valid_answers.each_with_index do |answer, i|
within("#question_#{question_2.id}_#{i}_result") do
expect(page).to have_content(answer)
expect(page).to have_content([0,15][i])
expect(page).to have_content([0, 15][i])
end
end

View File

@@ -29,7 +29,7 @@ feature 'Users' do
expect(user).to be_level_three_verified
expect(user).to be_residence_verified
expect(user).to_not be_confirmed
expect(user.date_of_birth).to have_content (Date.new(1980,12,31))
expect(user.date_of_birth).to have_content (Date.new(1980, 12, 31))
sent_token = /.*confirmation_token=(.*)".*/.match(ActionMailer::Base.deliveries.last.body.to_s)[1]
visit user_confirmation_path(confirmation_token: sent_token)
@@ -69,7 +69,7 @@ feature 'Users' do
expect(user).to be_level_three_verified
expect(user).to be_residence_verified
expect(user).to be_confirmed
expect(user.date_of_birth).to have_content (Date.new(1980,12,31))
expect(user.date_of_birth).to have_content (Date.new(1980, 12, 31))
end
scenario 'Delete a level 2 user account from document verification page', :js do

View File

@@ -289,9 +289,9 @@ feature 'Valuation budget investments' do
end
scenario 'Feasibility selection makes proper fields visible', :js do
feasible_fields = ['Price (€)','Cost during the first year (€)','Price explanation','Time scope']
feasible_fields = ['Price (€)', 'Cost during the first year (€)', 'Price explanation', 'Time scope']
unfeasible_fields = ['Feasibility explanation']
any_feasibility_fields = ['Valuation finished','Internal comments']
any_feasibility_fields = ['Valuation finished', 'Internal comments']
undecided_fields = feasible_fields + unfeasible_fields + any_feasibility_fields
visit edit_valuation_budget_budget_investment_path(@budget, @investment)

View File

@@ -311,9 +311,9 @@ feature 'Valuation spending proposals' do
end
scenario 'Feasibility selection makes proper fields visible', :js do
feasible_true_fields = ['Price (€)','Cost during the first year (€)','Price explanation','Time scope']
feasible_true_fields = ['Price (€)', 'Cost during the first year (€)', 'Price explanation', 'Time scope']
feasible_false_fields = ['Feasibility explanation']
feasible_any_fields = ['Valuation finished','Internal comments']
feasible_any_fields = ['Valuation finished', 'Internal comments']
feasible_nil_fields = feasible_true_fields + feasible_false_fields + feasible_any_fields
visit edit_valuation_spending_proposal_path(@spending_proposal)

View File

@@ -39,7 +39,7 @@ describe CensusApi do
response = api.call(1, "123456")
expect(response).to be_valid
expect(response.date_of_birth).to eq(Date.new(1980,1,1))
expect(response.date_of_birth).to eq(Date.new(1980, 1, 1))
end
it "returns the last failed response" do

View File

@@ -48,7 +48,7 @@ describe "Abilities::Moderator" do
describe "hiding, reviewing and restoring" do
let(:ignored_comment) { create(:comment, :with_ignored_flag) }
let(:ignored_debate) { create(:debate, :with_ignored_flag) }
let(:ignored_proposal) { create(:proposal,:with_ignored_flag) }
let(:ignored_proposal) { create(:proposal, :with_ignored_flag) }
it { should be_able_to(:hide, comment) }
it { should be_able_to(:hide_in_moderation_screen, comment) }

View File

@@ -249,7 +249,7 @@ describe Budget::Investment do
by_valuator = Budget::Investment.by_valuator(valuator1.id)
expect(by_valuator.size).to eq(2)
expect(by_valuator.sort).to eq([investment1,investment3].sort)
expect(by_valuator.sort).to eq([investment1, investment3].sort)
end
end

View File

@@ -39,7 +39,7 @@ describe Verification::Management::Email do
allow(validation).to receive(:user).and_return user
expect(mail).to receive(:deliver_later)
expect(Devise.token_generator).to receive(:generate).with(User, :email_verification_token).and_return(["1","2"])
expect(Devise.token_generator).to receive(:generate).with(User, :email_verification_token).and_return(["1", "2"])
expect(Mailer).to receive(:email_verification).with(user, user.email, "2", "1", "1234").and_return(mail)
validation.save