From 1de763a737e017ac0976fc0d9e3ffc7704d862ac Mon Sep 17 00:00:00 2001 From: decabeza Date: Wed, 6 Sep 2017 18:07:46 +0200 Subject: [PATCH] removes deprecated specs --- spec/models/poll/poll_spec.rb | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/spec/models/poll/poll_spec.rb b/spec/models/poll/poll_spec.rb index 2eb78841b..ac0cc44ea 100644 --- a/spec/models/poll/poll_spec.rb +++ b/spec/models/poll/poll_spec.rb @@ -67,31 +67,15 @@ describe :poll do current = create(:poll, :current) incoming = create(:poll, :incoming) expired = create(:poll, :expired) - + current_or_incoming = Poll.current_or_incoming - + expect(current_or_incoming).to include(current) expect(current_or_incoming).to include(incoming) expect(current_or_incoming).to_not include(expired) end end - describe "#document_has_voted?" do - it "returns true if Poll::Voter with document exists" do - poll = create(:poll) - voter = create(:poll_voter, :valid_document, poll: poll) - - expect(poll.document_has_voted?(voter.document_number, voter.document_type)).to eq(true) - end - - it "returns false if Poll::Voter with document does not exists" do - poll_2 = create(:poll) - voter = create(:poll_voter, :valid_document, poll: poll_2) - - expect(poll.document_has_voted?(voter.document_number, voter.document_type)).to eq(false) - end - end - describe "answerable_by" do let(:geozone) {create(:geozone) }