public function test_it_returns_player_name() { $this->assertEquals(self::PLAYER_NAME, $this->player->getName()); }
/** * @param Player|null $winner */ private function showResult(Player $winner = null) { $result = null === $winner ? "it's a draw!\n" : sprintf("%s has won! Congrats.\n", $winner->getName()); $this->ioService->printMessageLine("End of the game: " . $result); }