Add consideration of playoff tiebreakers.

This commit is contained in:
Patrick Fairbank
2022-08-21 14:42:47 -07:00
parent 0fdfc78a7b
commit 20cb056243
21 changed files with 201 additions and 155 deletions

View File

@@ -6,6 +6,7 @@
package bracket
import (
"github.com/Team254/cheesy-arena-lite/game"
"github.com/Team254/cheesy-arena-lite/model"
"github.com/stretchr/testify/assert"
"testing"
@@ -27,7 +28,7 @@ func assertMatch(t *testing.T, match model.Match, displayName string, redAllianc
assert.Equal(t, 100*blueAlliance+3, match.Blue3)
}
func scoreMatch(database *model.Database, displayName string, winner model.MatchStatus) {
func scoreMatch(database *model.Database, displayName string, winner game.MatchStatus) {
match, _ := database.GetMatchByName("elimination", displayName)
match.Status = winner
database.UpdateMatch(match)