]> projects.mako.cc - rubyvote/blobdiff - test/positional_test.rb
a number of improvements
[rubyvote] / test / positional_test.rb
index 1dc6c125099a80126517bc4bc8c0e7542e547fee..bb81c7ec7109729c9652266aa3ed65bc67a0dba3 100644 (file)
@@ -5,7 +5,13 @@ require 'rubyvote/election'
 require 'rubyvote/positional'
 
 class TestPositionalVote < Test::Unit::TestCase
-
+  
+  def test_borda_empty
+    vote_array = Array.new
+    assert_nil BordaVote.new(vote_array).result.winners[0]
+    assert_equal(false, BordaVote.new(vote_array).result.winner?)
+  end
+  
   def test_borda
     vote_array = Array.new
     2.times {vote_array << "BAC".split("")}

Benjamin Mako Hill || Want to submit a patch?