/**
  * @test
  */
 public function itShouldBuildTheCommand()
 {
     $command = JoinGameCommand::create($this->gameId, $this->playerId, $this->playerOptions, $this->context);
     $this->assertEquals($this->playerId, $command->getPlayerId());
     $this->assertEquals($this->gameId, $command->getGameId());
     $this->assertEquals($this->playerOptions, $command->getPlayerOptions());
     $this->assertEquals($this->context, $command->getContext());
     $this->assertEquals(JoinGameCommand::NAME, $command->getCommandName());
 }
 /**
  * @test
  */
 public function itShouldFailJoiningGame()
 {
     $command = JoinGameCommand::create($this->gameId, $this->playerId, $this->playerOptions, $this->context);
     $this->givenGameExists();
     $this->givenItCanNotAddAPlayerToGame();
     $this->assertErrorWillBeHandled();
     $this->assertGameStateWontChange();
     $this->miniGameCommandHandler->handleJoinGameCommand($command);
 }