From da5d782e4008d96316d4478fd9053f0ef3d5c11f Mon Sep 17 00:00:00 2001 From: Jens True Date: Tue, 21 May 2024 12:24:59 +0000 Subject: [PATCH] Simplifying --- docs/index.rst | 3 +-- src/SkillCalculator.php | 6 ++++++ src/SkillCalculatorSupportedOptions.php | 14 -------------- src/TrueSkill/FactorGraphTrueSkillCalculator.php | 3 +-- src/TrueSkill/TwoPlayerTrueSkillCalculator.php | 4 +--- src/TrueSkill/TwoTeamTrueSkillCalculator.php | 3 +-- .../FactorGraphTrueSkillCalculatorTest.php | 4 ++-- 7 files changed, 12 insertions(+), 25 deletions(-) delete mode 100644 src/SkillCalculatorSupportedOptions.php diff --git a/docs/index.rst b/docs/index.rst index d4d1000..e646356 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -30,9 +30,8 @@ Links * `Project README `_ * `API Documentations `_ * `CodeCoverage `_ -* `Metrics `_ * `Test report `_ -* `Mutation testing `_ +* `Mutation testing `_ Standard Tools diff --git a/src/SkillCalculator.php b/src/SkillCalculator.php index 9aedd73..5ef4572 100644 --- a/src/SkillCalculator.php +++ b/src/SkillCalculator.php @@ -11,6 +11,12 @@ use Exception; */ abstract class SkillCalculator { + public const NONE = 0x00; + + public const PARTIAL_PLAY = 0x01; + + public const PARTIAL_UPDATE = 0x02; + protected function __construct( private readonly int $supportedOptions, private readonly TeamsRange $totalTeamsAllowed, diff --git a/src/SkillCalculatorSupportedOptions.php b/src/SkillCalculatorSupportedOptions.php deleted file mode 100644 index ac7895d..0000000 --- a/src/SkillCalculatorSupportedOptions.php +++ /dev/null @@ -1,14 +0,0 @@ -assertEquals(TRUE, $calculator->isSupported(SkillCalculatorSupportedOptions::PARTIAL_PLAY)); + $this->assertEquals(TRUE, $calculator->isSupported(SkillCalculator::PARTIAL_PLAY)); } }