-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Verify poll ballots #2858
Verify poll ballots #2858
Conversation
b31533c
to
985b9ad
Compare
cbe16cb
to
412e765
Compare
412e765
to
d573581
Compare
expect(poll_ballot.add_investment(investment.id)).to be(true) | ||
|
||
other_heading = create(:budget_heading, group: group, price: 10000000) | ||
other_investment = create(:budget_investment, :selected, price: 1000000, heading: other_heading) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Metrics/LineLength: Line is too long. [104/100] (https://github.com/bbatsov/ruby-style-guide#80-character-limits)
poll_ballot.verify | ||
|
||
expect(poll_ballot.ballot.lines.count).to eq(3) | ||
expect(poll_ballot.ballot.lines.pluck(:investment_id).sort).to eq([investment.id, investment2.id, investment3.id].sort) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Metrics/LineLength: Line is too long. [125/100] (https://github.com/bbatsov/ruby-style-guide#80-character-limits)
investment3 = create(:budget_investment, :selected, price: 2000000, heading: heading) | ||
investment4 = create(:budget_investment, :selected, price: 2000000, heading: heading) | ||
|
||
poll_ballot.update(data: [investment.id, investment2.id, investment3.id, investment4.id].join(",")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Metrics/LineLength: Line is too long. [105/100] (https://github.com/bbatsov/ruby-style-guide#80-character-limits)
let(:investment){ create(:budget_investment, :selected, price: 5000000, heading: heading) } | ||
let(:poll) { create(:poll, budget: budget) } | ||
let(:poll_ballot_sheet) { create(:poll_ballot_sheet, poll: poll) } | ||
let(:poll_ballot) { create(:poll_ballot, ballot_sheet: poll_ballot_sheet, external_id: 1, data: investment.id) } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Metrics/LineLength: Line is too long. [114/100] (https://github.com/bbatsov/ruby-style-guide#80-character-limits)
d573581
to
ea8477c
Compare
ea8477c
to
ea8ef72
Compare
ea8ef72
to
aeb8410
Compare
References
Objectives
Verify
poll ballots
and create the correspondingbudget ballot lines
Notes
The parts related to
city_heading
, which are specific to Madrid, have not been backported.