| @@ -65,7 +65,7 @@ | ||
| 65 | 65 |          $objects = $this->loadFixturesFromFile('books.yml'); | 
| 66 | 66 | |
| 67 | 67 | $data = | 
| 68 | - <<<EOT | |
| 68 | + <<<EOT | |
| 69 | 69 |          { | 
| 70 | 70 | "title": "Star Wars: Dark Disciple" | 
| 71 | 71 | } | 
| @@ -63,7 +63,7 @@ discard block | ||
| 63 | 63 | } | 
| 64 | 64 | EOT; | 
| 65 | 65 | |
| 66 | -        $this->client->request('PUT', '/books/'. $objects["book1"]->getId(), [], [], ['CONTENT_TYPE' => 'application/json'], $data); | |
| 66 | +        $this->client->request('PUT', '/books/' . $objects["book1"]->getId(), [], [], ['CONTENT_TYPE' => 'application/json'], $data); | |
| 67 | 67 | $response = $this->client->getResponse(); | 
| 68 | 68 | $this->assertResponseCode($response, Response::HTTP_NO_CONTENT); | 
| 69 | 69 | } | 
| @@ -82,7 +82,7 @@ discard block | ||
| 82 | 82 | } | 
| 83 | 83 | EOT; | 
| 84 | 84 | |
| 85 | -        $this->client->request('PATCH', '/books/'. $objects["book1"]->getId(), [], [], ['CONTENT_TYPE' => 'application/json'], $data); | |
| 85 | +        $this->client->request('PATCH', '/books/' . $objects["book1"]->getId(), [], [], ['CONTENT_TYPE' => 'application/json'], $data); | |
| 86 | 86 | $response = $this->client->getResponse(); | 
| 87 | 87 | $this->assertResponseCode($response, Response::HTTP_NO_CONTENT); | 
| 88 | 88 | } | 
| @@ -94,7 +94,7 @@ discard block | ||
| 94 | 94 |      { | 
| 95 | 95 |          $objects = $this->loadFixturesFromFile('books.yml'); | 
| 96 | 96 | |
| 97 | -        $this->client->request('DELETE', '/books/'. $objects["book1"]->getId()); | |
| 97 | +        $this->client->request('DELETE', '/books/' . $objects["book1"]->getId()); | |
| 98 | 98 | $response = $this->client->getResponse(); | 
| 99 | 99 | $this->assertResponseCode($response, Response::HTTP_NO_CONTENT); | 
| 100 | 100 | } | 
| @@ -106,7 +106,7 @@ discard block | ||
| 106 | 106 |      { | 
| 107 | 107 |          $objects = $this->loadFixturesFromFile('books.yml'); | 
| 108 | 108 | |
| 109 | -        $this->client->request('GET', '/books/'. $objects["book1"]->getId()); | |
| 109 | +        $this->client->request('GET', '/books/' . $objects["book1"]->getId()); | |
| 110 | 110 | $response = $this->client->getResponse(); | 
| 111 | 111 | $this->assertResponse($response, 'books/show_response'); | 
| 112 | 112 | } | 
| @@ -34,7 +34,7 @@ discard block | ||
| 34 | 34 | }, | 
| 35 | 35 | "author": "Christie Golden" | 
| 36 | 36 | } | 
| 37 | -EOT; | |
| 37 | +eot; | |
| 38 | 38 | |
| 39 | 39 |          $this->client->request('POST', '/books/', [], [], ['CONTENT_TYPE' => 'application/json'], $data); | 
| 40 | 40 | $response = $this->client->getResponse(); | 
| @@ -61,7 +61,7 @@ discard block | ||
| 61 | 61 | }, | 
| 62 | 62 | "author": "Christie Golden" | 
| 63 | 63 | } | 
| 64 | -EOT; | |
| 64 | +eot; | |
| 65 | 65 | |
| 66 | 66 |          $this->client->request('PUT', '/books/'. $objects["book1"]->getId(), [], [], ['CONTENT_TYPE' => 'application/json'], $data); | 
| 67 | 67 | $response = $this->client->getResponse(); | 
| @@ -80,7 +80,7 @@ discard block | ||
| 80 | 80 |          { | 
| 81 | 81 | "author": "Christie Golden" | 
| 82 | 82 | } | 
| 83 | -EOT; | |
| 83 | +eot; | |
| 84 | 84 | |
| 85 | 85 |          $this->client->request('PATCH', '/books/'. $objects["book1"]->getId(), [], [], ['CONTENT_TYPE' => 'application/json'], $data); | 
| 86 | 86 | $response = $this->client->getResponse(); | 
| @@ -51,13 +51,13 @@ | ||
| 51 | 51 | |
| 52 | 52 |          foreach ($securityRoles as $securityRole) { | 
| 53 | 53 |              if (!$user->hasRole($securityRole)) { | 
| 54 | -                $output->writeln(sprintf('<error>User "%s" didn\'t have "%s" Security role.</error>', (string)$user, $securityRole)); | |
| 54 | +                $output->writeln(sprintf('<error>User "%s" didn\'t have "%s" Security role.</error>', (string) $user, $securityRole)); | |
| 55 | 55 | $error = true; | 
| 56 | 56 | continue; | 
| 57 | 57 | } | 
| 58 | 58 | |
| 59 | 59 | $user->removeRole($securityRole); | 
| 60 | -            $output->writeln(sprintf('Security role <comment>%s</comment> has been removed from user <comment>%s</comment>', $securityRole, (string)$user)); | |
| 60 | +            $output->writeln(sprintf('Security role <comment>%s</comment> has been removed from user <comment>%s</comment>', $securityRole, (string) $user)); | |
| 61 | 61 | } | 
| 62 | 62 | |
| 63 | 63 |          if (!$error) { | 
| @@ -30,7 +30,7 @@ | ||
| 30 | 30 |              ->setDescription('Initialize default permissions & roles in the application.') | 
| 31 | 31 | ->setHelp(<<<EOT | 
| 32 | 32 | The <info>%command.name%</info> command initializes default RBAC setup. | 
| 33 | -EOT | |
| 33 | +eot | |
| 34 | 34 | ) | 
| 35 | 35 | ; | 
| 36 | 36 | } | 
| @@ -163,7 +163,7 @@ | ||
| 163 | 163 | */ | 
| 164 | 164 | public function orderBy($field, $direction) | 
| 165 | 165 |      { | 
| 166 | - $this->orderBys = [ $field => $direction ]; | |
| 166 | + $this->orderBys = [$field => $direction]; | |
| 167 | 167 | } | 
| 168 | 168 | |
| 169 | 169 | /** | 
| @@ -76,7 +76,7 @@ | ||
| 76 | 76 |      { | 
| 77 | 77 | $this->shouldThrow( | 
| 78 | 78 |              new \RuntimeException('Unknown restrict condition "foo"') | 
| 79 | -        )->during('restrict', [ $comparison, 'foo' ]); | |
| 79 | +        )->during('restrict', [$comparison, 'foo']); | |
| 80 | 80 | } | 
| 81 | 81 | |
| 82 | 82 | function it_should_return_the_expression_builder( | 
| @@ -51,13 +51,13 @@ | ||
| 51 | 51 | |
| 52 | 52 |          foreach ($securityRoles as $securityRole) { | 
| 53 | 53 |              if ($user->hasRole($securityRole)) { | 
| 54 | -                $output->writeln(sprintf('<error>User "%s" did already have "%s" security role.</error>', (string)$user, $securityRole)); | |
| 54 | +                $output->writeln(sprintf('<error>User "%s" did already have "%s" security role.</error>', (string) $user, $securityRole)); | |
| 55 | 55 | $error = true; | 
| 56 | 56 | continue; | 
| 57 | 57 | } | 
| 58 | 58 | |
| 59 | 59 | $user->addRole($securityRole); | 
| 60 | -            $output->writeln(sprintf('Security role <comment>%s</comment> has been added to user <comment>%s</comment>', $securityRole, (string)$user)); | |
| 60 | +            $output->writeln(sprintf('Security role <comment>%s</comment> has been added to user <comment>%s</comment>', $securityRole, (string) $user)); | |
| 61 | 61 | } | 
| 62 | 62 | |
| 63 | 63 |          if (!$error) { | 
| @@ -30,7 +30,7 @@ | ||
| 30 | 30 |              ->setDescription('Initialize default permissions & roles in the application.') | 
| 31 | 31 | ->setHelp(<<<EOT | 
| 32 | 32 | The <info>%command.name%</info> command initializes default RBAC setup. | 
| 33 | -EOT | |
| 33 | +eot | |
| 34 | 34 | ) | 
| 35 | 35 | ; | 
| 36 | 36 | } | 
| @@ -82,7 +82,7 @@ | ||
| 82 | 82 | $this->summaryPage->open(); | 
| 83 | 83 | |
| 84 | 84 | Assert::true( | 
| 85 | - $this->summaryPage->isEmpty(), | |
| 85 | + $this->summaryPage->isEmpty(), | |
| 86 | 86 | 'There should appear information about empty cart, but it does not.' | 
| 87 | 87 | ); | 
| 88 | 88 | } | 
| @@ -49,7 +49,7 @@ | ||
| 49 | 49 |          $documentManager->getClassMetadata('stdClass')->willReturn($metadata); | 
| 50 | 50 | $metadata->nodename = null; | 
| 51 | 51 | |
| 52 | -        $this->shouldThrow(new \RuntimeException('In order to use the node name filter on "stdClass" it is necessary to map a field as the "nodename"'))->during('onEvent', [ $event ]); | |
| 52 | +        $this->shouldThrow(new \RuntimeException('In order to use the node name filter on "stdClass" it is necessary to map a field as the "nodename"'))->during('onEvent', [$event]); | |
| 53 | 53 | } | 
| 54 | 54 | |
| 55 | 55 | function it_should_clean_the_name( | 
| @@ -50,7 +50,7 @@ | ||
| 50 | 50 | $metadata->idGenerator = 'foo'; | 
| 51 | 51 | |
| 52 | 52 |          $this->shouldThrow(new \RuntimeException('Document of class "stdClass" must be using the GENERATOR_TYPE_PARENT identificatio strategy (value 3), it is current using "foo" (this may be an automatic configuration: be sure to map both the `nodename` and the `parentDocument`).'))->during( | 
| 53 | - 'onEvent', [ $event ] | |
| 53 | + 'onEvent', [$event] | |
| 54 | 54 | ); | 
| 55 | 55 | } | 
| 56 | 56 | |
| @@ -58,7 +58,7 @@ discard block | ||
| 58 | 58 | 'A default parent path has been specified, but no parent mapping has been applied to document "stdClass"' | 
| 59 | 59 | ))->during( | 
| 60 | 60 | 'onPreCreate', | 
| 61 | - [ $event ] | |
| 61 | + [$event] | |
| 62 | 62 | ); | 
| 63 | 63 | } | 
| 64 | 64 | |
| @@ -84,7 +84,7 @@ discard block | ||
| 84 | 84 | 'Document at default parent path "/path/to" does not exist. `autocreate` was set to "false"' | 
| 85 | 85 | ))->during( | 
| 86 | 86 | 'onPreCreate', | 
| 87 | - [ $event ] | |
| 87 | + [$event] | |
| 88 | 88 | ); | 
| 89 | 89 | } | 
| 90 | 90 | |