Don't include current polls in recounting polls

On the day when a poll ends, it was considered both current and
recounting.
This commit is contained in:
Javi Martín
2022-09-07 19:44:23 +02:00
parent 2153bd9e98
commit 3543767951
2 changed files with 2 additions and 2 deletions

View File

@@ -358,7 +358,7 @@ describe Poll do
describe ".recounting" do
it "returns polls in recount & scrutiny phase" do
about_to_start = create(:poll, starts_at: Date.tomorrow)
about_to_end = create(:poll, ends_at: Date.tomorrow)
about_to_end = create(:poll, ends_at: Date.current)
just_ended = create(:poll, ends_at: Date.yesterday)
recounting_ended = create(:poll, starts_at: 3.years.ago, ends_at: 2.years.ago)