projects
/
rubyvote
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
#filter_out and PureCondorcet weren't getting along well for sparse elections
[rubyvote]
/
test
/
condorcet_test.rb
diff --git
a/test/condorcet_test.rb
b/test/condorcet_test.rb
index 82ff292f6dae361511d876cc22edaf7076cf1a3b..f0dd1cc016d1ec97faec7f81d856b82dc83721d5 100644
(file)
--- a/
test/condorcet_test.rb
+++ b/
test/condorcet_test.rb
@@
-98,4
+98,13
@@
class TestCondorcetVote < Test::Unit::TestCase
assert_equal [[78]], result.get_full_results
end
assert_equal [[78]], result.get_full_results
end
+ def test_ssd_sparse
+ vote_array = Array.new
+ vote_array << ['B', 'D']
+ vote_array << ['A', 'C']
+ vote_array << ['E', 'C']
+ result = CloneproofSSDVote.new(vote_array).result
+ assert_equal 5, result.get_full_results.flatten.size
+ end
+
end
end
Benjamin Mako Hill
||
Want to submit a patch?