X-Git-Url: https://projects.mako.cc/source/rubyvote/blobdiff_plain/1da0a60f448820070d47333a7316364e009f203e..11d22a5307695910493266b16718e1ffa201676d:/test/range_test.rb?ds=sidebyside diff --git a/test/range_test.rb b/test/range_test.rb index 26d8600..799ba3f 100644 --- a/test/range_test.rb +++ b/test/range_test.rb @@ -6,6 +6,12 @@ require 'rubyvote/range' class TestRangeVote < Test::Unit::TestCase + def test_range_empty + vote_array = [] + assert_nil RangeVote.new(vote_array).result.winners[0] + assert_equal(false, RangeVote.new(vote_array).result.winner?) + end + def test_range vote_array = [] 42.times {vote_array << {'A' => 10, 'B' => 5, 'C' => 2, 'D' => 1}}