Completed
Pull Request — master (#102)
by Arnaud
07:20 queued 04:48
created
Tests/AdminBundle/Doctrine/Repository/DoctrineRepositoryTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
         
55 55
         $repository = new FakeRepository($entityManager, $metadata, TestEntity::class);
56 56
     
57
-        $this->assertExceptionRaised(\LogicException::class, function () use ($repository, $entity) {
57
+        $this->assertExceptionRaised(\LogicException::class, function() use ($repository, $entity) {
58 58
             $repository->save($entity);
59 59
         });
60 60
     }
@@ -103,7 +103,7 @@  discard block
 block discarded – undo
103 103
         
104 104
         $repository = new FakeRepository($entityManager, $metadata, TestEntity::class);
105 105
         
106
-        $this->assertExceptionRaised(\LogicException::class, function () use ($repository, $entity) {
106
+        $this->assertExceptionRaised(\LogicException::class, function() use ($repository, $entity) {
107 107
             $repository->delete($entity);
108 108
         });
109 109
     }
Please login to merge, or discard this patch.
src/LAG/AdminBundle/Tests/AdminBundle/Form/Factory/FormFactoryTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@
 block discarded – undo
45 45
      */
46 46
     protected function invalidEntityTest(FormFactory $formFactory, AdminInterface $admin)
47 47
     {
48
-        $this->assertExceptionRaised(Exception::class, function () use ($formFactory, $admin) {
48
+        $this->assertExceptionRaised(Exception::class, function() use ($formFactory, $admin) {
49 49
             $formFactory->create(
50 50
                 TestFormType::class,
51 51
                 [],
Please login to merge, or discard this patch.
Tests/AdminBundle/DataProvider/Factory/DataProviderFactoryTest.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
         $factory = new DataProviderFactory($entityManager);
43 43
         $factory->add('a_data_provider', $dataProvider);
44 44
 
45
-        $this->assertExceptionRaised(Exception::class, function () use ($factory, $dataProvider) {
45
+        $this->assertExceptionRaised(Exception::class, function() use ($factory, $dataProvider) {
46 46
             $factory->add('a_data_provider', $dataProvider);
47 47
         });
48 48
     }
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
 
95 95
         $factory = new DataProviderFactory($entityManager);
96 96
 
97
-        $this->assertExceptionRaised(Exception::class, function () use ($factory) {
97
+        $this->assertExceptionRaised(Exception::class, function() use ($factory) {
98 98
             $factory->create('MyEntityClass');
99 99
         });
100 100
     }
@@ -108,10 +108,10 @@  discard block
 block discarded – undo
108 108
         $factory->add('a_data_provider', $dataProvider);
109 109
 
110 110
         $this->assertEquals($dataProvider, $factory->get('a_data_provider'));
111
-        $this->assertExceptionRaised(Exception::class, function () use ($factory) {
111
+        $this->assertExceptionRaised(Exception::class, function() use ($factory) {
112 112
             $factory->get('wrong_data_provider');
113 113
         });
114
-        $this->assertExceptionRaised(Exception::class, function () use ($factory) {
114
+        $this->assertExceptionRaised(Exception::class, function() use ($factory) {
115 115
             $factory->get(null, null);
116 116
         });
117 117
     }
Please login to merge, or discard this patch.
src/LAG/AdminBundle/Tests/AdminBundle/Configuration/ConfigurationTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@
 block discarded – undo
36 36
             'title' => 'Planet Application',
37 37
         ]);
38 38
     
39
-        $this->assertExceptionRaised(LogicException::class, function () use ($configuration) {
39
+        $this->assertExceptionRaised(LogicException::class, function() use ($configuration) {
40 40
             $configuration->setParameters([
41 41
                 'an_other_configuration' => 'value',
42 42
             ]);
Please login to merge, or discard this patch.
LAG/AdminBundle/Tests/AdminBundle/Event/Subscriber/KernelSubscriberTest.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
         $requestHandler
38 38
             ->expects($this->once())
39 39
             ->method('supports')
40
-            ->willReturn(function ($givenRequest) use ($request) {
40
+            ->willReturn(function($givenRequest) use ($request) {
41 41
                 $this->assertEquals($givenRequest, $request);
42 42
 
43 43
                 return true;
@@ -49,14 +49,14 @@  discard block
 block discarded – undo
49 49
         $event
50 50
             ->expects($this->once())
51 51
             ->method('getRequest')
52
-            ->willReturnCallback(function () use ($request) {
52
+            ->willReturnCallback(function() use ($request) {
53 53
                 return $request;
54 54
             })
55 55
         ;
56 56
         $event
57 57
             ->expects($this->once())
58 58
             ->method('getController')
59
-            ->willReturnCallback(function () use ($controller) {
59
+            ->willReturnCallback(function() use ($controller) {
60 60
                 return $controller;
61 61
             })
62 62
         ;
Please login to merge, or discard this patch.
src/LAG/AdminBundle/Tests/AdminBundle/Admin/Request/RequestHandlerTest.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -91,12 +91,12 @@  discard block
 block discarded – undo
91 91
 
92 92
         $handler = new RequestHandler($registry);
93 93
 
94
-        $this->assertExceptionRaised(Exception::class, function () use ($handler) {
94
+        $this->assertExceptionRaised(Exception::class, function() use ($handler) {
95 95
             $request = new Request();
96 96
             $handler->handle($request);
97 97
         });
98 98
 
99
-        $this->assertExceptionRaised(Exception::class, function () use ($handler) {
99
+        $this->assertExceptionRaised(Exception::class, function() use ($handler) {
100 100
             $request = new Request([], [], [
101 101
                 '_route_params' => [
102 102
                     '_action' => 'list',
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
             $handler->handle($request);
106 106
         });
107 107
 
108
-        $this->assertExceptionRaised(Exception::class, function () use ($handler) {
108
+        $this->assertExceptionRaised(Exception::class, function() use ($handler) {
109 109
             $request = new Request([], [], [
110 110
                 '_route_params' => [
111 111
                     '_admin' => 'wookie',
Please login to merge, or discard this patch.
src/LAG/AdminBundle/Tests/AdminBundle/Admin/AdminTest.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
         $authorizationChecker
37 37
             ->expects($this->atLeastOnce())
38 38
             ->method('isGranted')
39
-            ->willReturnCallback(function ($roles) {
39
+            ->willReturnCallback(function($roles) {
40 40
                 $this->assertEquals([
41 41
                     'ROLE_USER',
42 42
                 ], $roles);
@@ -246,7 +246,7 @@  discard block
 block discarded – undo
246 246
             ]
247 247
         );
248 248
 
249
-        $this->assertExceptionRaised(AccessDeniedException::class, function () use ($request, $admin) {
249
+        $this->assertExceptionRaised(AccessDeniedException::class, function() use ($request, $admin) {
250 250
             $admin->handleRequest($request);
251 251
         });
252 252
     }
@@ -302,7 +302,7 @@  discard block
 block discarded – undo
302 302
             ]
303 303
         );
304 304
 
305
-        $this->assertExceptionRaised(LogicException::class, function () use ($admin) {
305
+        $this->assertExceptionRaised(LogicException::class, function() use ($admin) {
306 306
             $admin->checkPermissions();
307 307
         });
308 308
     }
@@ -392,7 +392,7 @@  discard block
 block discarded – undo
392 392
             ]
393 393
         );
394 394
 
395
-        $this->assertExceptionRaised(AccessDeniedException::class, function () use ($admin, $request) {
395
+        $this->assertExceptionRaised(AccessDeniedException::class, function() use ($admin, $request) {
396 396
             $admin->handleRequest($request);
397 397
         });
398 398
     }
@@ -419,7 +419,7 @@  discard block
 block discarded – undo
419 419
         $authorizationChecker
420 420
             ->expects($this->exactly(2))
421 421
             ->method('isGranted')
422
-            ->willReturnCallback(function () use (&$i) {
422
+            ->willReturnCallback(function() use (&$i) {
423 423
                 ++$i;
424 424
 
425 425
                 return $i <= 1;
@@ -499,7 +499,7 @@  discard block
 block discarded – undo
499 499
             ]
500 500
         );
501 501
 
502
-        $this->assertExceptionRaised(AccessDeniedException::class, function () use ($admin, $request) {
502
+        $this->assertExceptionRaised(AccessDeniedException::class, function() use ($admin, $request) {
503 503
             $admin->handleRequest($request);
504 504
             $admin->checkPermissions();
505 505
         });
Please login to merge, or discard this patch.
src/LAG/AdminBundle/Tests/AdminBundle/Admin/Factory/AdminFactoryTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -142,7 +142,7 @@
 block discarded – undo
142 142
         $eventDispatcher
143 143
             ->expects($this->once())
144 144
             ->method('dispatch')
145
-            ->willReturnCallback(function ($name, $event) {
145
+            ->willReturnCallback(function($name, $event) {
146 146
                 $this->assertEquals(AdminEvents::ADMIN_INJECTED, $name);
147 147
                 $this->assertInstanceOf(AdminInjectedEvent::class, $event);
148 148
             })
Please login to merge, or discard this patch.
src/LAG/AdminBundle/Tests/AdminBundle/Admin/Registry/RegistryTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
         $registry->add($admin);
23 23
 
24 24
         // an exception SHOULD be thrown if an Admin with the same has already been registered
25
-        $this->assertExceptionRaised(Exception::class, function () use ($registry, $admin) {
25
+        $this->assertExceptionRaised(Exception::class, function() use ($registry, $admin) {
26 26
             $registry->add($admin);
27 27
         });
28 28
 
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
         ], $registry->all());
33 33
         $this->assertTrue($registry->has('myAdmin'));
34 34
 
35
-        $this->assertExceptionRaised(Exception::class, function () use ($registry) {
35
+        $this->assertExceptionRaised(Exception::class, function() use ($registry) {
36 36
             $registry->get('wrong');
37 37
         });
38 38
     }
Please login to merge, or discard this patch.