Showing 153 of 153 total issues
Line exceeds 120 characters; contains 140 characters Open
Open
&& $this->validatePlayerName($data->playerName) // will be replaced by Authorization header which will reflect Player.id content
- Exclude checks
Line exceeds 120 characters; contains 137 characters Open
Open
$this->assertContains((string)$cell->flags, [CellModel::FLAG_NONE, CellModel::FLAG_SHIP, CellModel::FLAG_DEAD_SHIP]);
- Exclude checks
Line exceeds 120 characters; contains 129 characters Open
Open
$expected = $battlefield->player->flags == PlayerModel::FLAG_AI_CONTROLLED ? CellModel::FLAG_NONE : $cell->flags;
- Exclude checks
Line exceeds 120 characters; contains 121 characters Open
Open
throw new HttpException(Response::HTTP_BAD_REQUEST, 'request validation failed, please check documentation');
- Exclude checks
Line exceeds 120 characters; contains 139 characters Open
Open
foreach ($processor->reset($cell->getCoordinate())->getAdjacentCells($battlefield, 1, 0, CellModel::FLAG_SHIP) as $waterCell) {
- Exclude checks
Line exceeds 120 characters; contains 166 characters Open
Open
/** if path is HORIZONTAL, strategy should be HORIZONTAL otherwise VERTICAL @see AIStrategyService::$strategyMap contains only UP|DOWN|LEFT|RIGHT paths */
- Exclude checks
Line exceeds 120 characters; contains 126 characters Open
Open
return $this->prepareSerializedResponse(new GameInitiationResponse($game->getBattlefields()), Response::HTTP_CREATED);
- Exclude checks
Line exceeds 120 characters; contains 160 characters Open
Open
public function getAdjacentCells(string $initCoordinate, array $expectedCoordinates, Battlefield $battlefield, int $levels, int $onlyFlag, int $excludeFlag)
- Exclude checks
Line exceeds 120 characters; contains 137 characters Open
Open
* @ORM\OneToMany(targetEntity="EM\GameBundle\Entity\Battlefield", mappedBy="game", cascade={"persist"}, fetch="EAGER", indexBy="id")
- Exclude checks
Line exceeds 120 characters; contains 128 characters Open
Open
$game = $this->get('em.game_bundle.service.game_builder')->buildGame(new GameInitiationRequest($request->getContent()));
- Exclude checks
The method successfulInitAction_XML is not named in camelCase. Open
Open
public function successfulInitAction_XML()
{
$client = static::$client;
$client->request(
Request::METHOD_POST,
- Read upRead up
- Exclude checks
CamelCaseMethodName
Since: 0.2
It is considered best practice to use the camelCase notation to name methods.
Example
class ClassName {
public function get_name() {
}
}
Source
The method successfulInitAction_JSON is not named in camelCase. Open
Open
public function successfulInitAction_JSON()
{
$client = static::$client;
$client->request(
Request::METHOD_POST,
- Read upRead up
- Exclude checks
CamelCaseMethodName
Since: 0.2
It is considered best practice to use the camelCase notation to name methods.
Example
class ClassName {
public function get_name() {
}
}
Source
The method AdjacentCellsProvider is not named in camelCase. Open
Open
public function AdjacentCellsProvider() : array
{
$battlefield = MockFactory::getBattlefieldMock();
$battlefield->getCellByCoordinate('A2')->setFlags(CellModel::FLAG_DEAD);
- Read upRead up
- Exclude checks
CamelCaseMethodName
Since: 0.2
It is considered best practice to use the camelCase notation to name methods.
Example
class ClassName {
public function get_name() {
}
}