2010-09-23 22:14:56 -04:00
|
|
|
<?php
|
|
|
|
require_once 'PHPUnit/Framework.php';
|
|
|
|
require_once 'PHPUnit/TextUI/TestRunner.php';
|
|
|
|
|
2010-10-14 21:51:43 -04:00
|
|
|
require_once(dirname(__FILE__) . '/../../Skills/TrueSkill/FactorGraphTrueSkillCalculator.php');
|
2010-09-23 22:14:56 -04:00
|
|
|
require_once(dirname(__FILE__) . '/TrueSkillCalculatorTests.php');
|
|
|
|
|
|
|
|
use \PHPUnit_Framework_TestCase;
|
|
|
|
use Moserware\Skills\TrueSkill\FactorGraphTrueSkillCalculator;
|
|
|
|
|
|
|
|
class FactorGraphTrueSkillCalculatorTest extends PHPUnit_Framework_TestCase
|
|
|
|
{
|
|
|
|
public function testFactorGraphTrueSkillCalculator()
|
2010-10-02 21:15:47 -04:00
|
|
|
{
|
2010-09-23 22:14:56 -04:00
|
|
|
$calculator = new FactorGraphTrueSkillCalculator();
|
2010-09-25 10:15:51 -04:00
|
|
|
|
2010-09-23 22:14:56 -04:00
|
|
|
TrueSkillCalculatorTests::testAllTwoPlayerScenarios($this, $calculator);
|
|
|
|
TrueSkillCalculatorTests::testAllTwoTeamScenarios($this, $calculator);
|
2010-10-03 17:42:31 -04:00
|
|
|
TrueSkillCalculatorTests::testAllMultipleTeamScenarios($this, $calculator);
|
2010-10-03 19:16:17 -04:00
|
|
|
TrueSkillCalculatorTests::testPartialPlayScenarios($this, $calculator);
|
2010-09-23 22:14:56 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
$testSuite = new \PHPUnit_Framework_TestSuite();
|
2010-09-25 10:15:51 -04:00
|
|
|
$testSuite->addTest( new FactorGraphTrueSkillCalculatorTest("testFactorGraphTrueSkillCalculator"));
|
2010-09-23 22:14:56 -04:00
|
|
|
|
|
|
|
\PHPUnit_TextUI_TestRunner::run($testSuite);
|
|
|
|
?>
|