Ejemplo n.º 1
0
	def test_twoPlayerTestDrawn(self):
		player1 = Player(1)
		player2 = Player(2)
		gameInfo = defaultGameInfo()
	
		team1 = Team(player1, gameInfo.defaultRating)
		team2 = Team(player2, gameInfo.defaultRating)
		teams = [team1, team2]
	
		newRatings = self.calculator.calculateNewRatings(gameInfo, teams, [1, 1])
	
		for newRating in newRatings:
			self.assertRating(25.0, 6.4575196623173081, newRating[1])
		self.assertMatchQuality(0.447, self.calculator.calculateMatchQuality(gameInfo, teams))
Ejemplo n.º 2
0
	def setUp(self):
		self.calculator = TwoTeamTrueSkillCalculator()
		self.gameInfo = defaultGameInfo()
Ejemplo n.º 3
0
	def setUp(self):
		self.calculator = FactorGraphTrueSkillCalculator()
		self.gameInfo = defaultGameInfo()