コード例 #1
0
ファイル: Game101Test.php プロジェクト: thuliumcc/dartboard
 /**
  * @test
  * @dataProvider bestShotCalculate
  * @param $score
  * @param $expectedBestShots
  */
 public function shouldCalculateBestShot($score, $expectedBestShots)
 {
     //given
     $this->gameUser->updateAttributes(['score' => $score]);
     $game101 = new Game101($this->game);
     //when
     $bestShots = $game101->getPlayersBestShots();
     //then
     $this->assertEquals($expectedBestShots, Arrays::getValue($bestShots, $this->gameUser->getId(), []));
 }