From 30dc6453750cc33ec867725bfc836aa10c884306 Mon Sep 17 00:00:00 2001 From: Jacob Cody Wimer Date: Sat, 19 Jan 2019 15:20:54 +0000 Subject: [PATCH] Test to make sure eight pools to quarter run through all matches successfully --- test/integration/eight_pool_match_generation_test.rb | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/integration/eight_pool_match_generation_test.rb b/test/integration/eight_pool_match_generation_test.rb index ebe545b..87850d9 100644 --- a/test/integration/eight_pool_match_generation_test.rb +++ b/test/integration/eight_pool_match_generation_test.rb @@ -81,4 +81,12 @@ class EightPoolMatchGenerationTest < ActionDispatch::IntegrationTest match2.save assert wrestler.reload.placement_points == 9 end + + test "Run through all matches works" do + GenerateTournamentMatches.new(@tournament).generate + @tournament.matches.sort{ |match| match.round }.each do |match| + match.winner_id = match.w1 + match.save + end + end end