go.charczuk.com@v0.0.0-20240327042549-bc490516bd1a/experiments/matchmaker/pkg/sim/ratings_test.go (about) 1 /* 2 3 Copyright (c) 2024 - Present. Will Charczuk. All rights reserved. 4 Use of this source code is governed by a MIT license that can be found in the LICENSE file at the root of the repository. 5 6 */ 7 8 package sim 9 10 import ( 11 "testing" 12 13 "go.charczuk.com/sdk/assert" 14 ) 15 16 func Test_Simulation_calculatePlayerRating(t *testing.T) { 17 // todo 18 } 19 20 func Test_Simulation_calculateTeamRating(t *testing.T) { 21 s := new(Simulation) 22 23 teamA := []*Player{ 24 mockPlayer0(), 25 mockPlayer0(), 26 mockPlayer1(), 27 mockPlayer1(), 28 mockPlayer0(), 29 mockPlayer0(), 30 } 31 ar := s.calculateTeamRating(teamA) 32 assert.ItsEqual(t, 1533, ar) 33 }