4 require 'election_test_helper'
6 class TestElectionVote < Test::Unit::TestCase
7 include ElectionTestHelper
10 vote_array = "ABCABCABCCCBBAAABABABCCCCCCCCCCCCCA".split("")
12 test_winner( "C", PluralityVote.new(vote_array).result )
17 vote_array = Array.new
18 10.times {vote_array << "AB".split("")}
19 10.times {vote_array << "CB".split("")}
20 11.times {vote_array << "AC".split("")}
21 5.times {vote_array << "A".split("")}
23 test_winner( "A", ApprovalVote.new(vote_array).result )