Completed
Push — develop ( a73e2c...030f10 )
by Carsten
28:43 queued 13:31
created
module/Core/test/CoreTest/Controller/AdminControllerTest.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -44,8 +44,8 @@
 block discarded – undo
44 44
     protected function setUp()
45 45
     {
46 46
         $events = $this->getMockBuilder(EventManager::class)
47
-                       ->setMethods(['getEvent', 'trigger'])
48
-                       ->getMock();
47
+                        ->setMethods(['getEvent', 'trigger'])
48
+                        ->getMock();
49 49
         $this->target = new AdminController($events);
50 50
     }
51 51
 
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
      */
40 40
     protected $target = '\Core\Controller\AdminController';
41 41
 
42
-    protected $inheritance = [ 'Zend\Mvc\Controller\AbstractActionController' ];
42
+    protected $inheritance = ['Zend\Mvc\Controller\AbstractActionController'];
43 43
 
44 44
     protected function setUp()
45 45
     {
Please login to merge, or discard this patch.
module/Core/test/CoreTest/Controller/IndexControllerTest.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
     /**
47 47
      * @return IndexController
48 48
      */
49
-    public function setupTarget($auth=null, $layout=null, $forward=null, $config=null)
49
+    public function setupTarget($auth = null, $layout = null, $forward = null, $config = null)
50 50
     {
51 51
         $auth->expects($this->any())
52 52
             ->method('__invoke')
@@ -59,10 +59,10 @@  discard block
 block discarded – undo
59 59
         $plugins->expects($this->any())
60 60
             ->method('get')
61 61
             ->willReturnMap([
62
-                ['Auth',null,$auth],
63
-                ['layout',null,$layout],
64
-                ['forward',null,$forward],
65
-                ['config',null,$config]
62
+                ['Auth', null, $auth],
63
+                ['layout', null, $layout],
64
+                ['forward', null, $forward],
65
+                ['config', null, $config]
66 66
             ])
67 67
         ;
68 68
         $this->pluginsMock = $plugins;
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
             ->method('dispatch')
153 153
             ->with(
154 154
                 'Jobs/Index',
155
-                ['action' => 'dashboard','type'=>'recent']
155
+                ['action' => 'dashboard', 'type'=>'recent']
156 156
             )
157 157
             ->willReturnOnConsecutiveCalls(null, $viewModel)
158 158
         ;
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
         ;
166 166
 
167 167
         $target = $this->getMockBuilder(IndexController::class)
168
-            ->setConstructorArgs([$this->moduleManager,$this->config])
168
+            ->setConstructorArgs([$this->moduleManager, $this->config])
169 169
             ->setMethods(['getResponse'])
170 170
             ->getMock()
171 171
         ;
Please login to merge, or discard this patch.
Core/test/CoreTest/Factory/Controller/Plugin/SearchFormFactoryTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
      */
42 42
     protected $target = SearchFormFactory::class;
43 43
 
44
-    protected $inheritance = [ FactoryInterface::class ];
44
+    protected $inheritance = [FactoryInterface::class];
45 45
 
46 46
     public function testCreatesPluginAndInjectsFormElementManager()
47 47
     {
Please login to merge, or discard this patch.
module/Core/test/CoreTest/Factory/Controller/FileControllerFactoryTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -35,8 +35,8 @@
 block discarded – undo
35 35
         $container->expects($this->exactly(2))
36 36
             ->method('get')
37 37
             ->willReturnMap([
38
-                ['repositories',$repositories],
39
-                ['Core/File/Events',$coreFileEvents]
38
+                ['repositories', $repositories],
39
+                ['Core/File/Events', $coreFileEvents]
40 40
             ])
41 41
         ;
42 42
 
Please login to merge, or discard this patch.
module/Core/test/CoreTest/Factory/LazyControllerFactoryTest.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -56,10 +56,10 @@  discard block
 block discarded – undo
56 56
         $container->expects($this->any())
57 57
             ->method('get')
58 58
             ->willReturnMap([
59
-                ['config',$config],
60
-                ['ModuleManager',$moduleManager],
61
-                ['repositories',$repositories],
62
-                ['Core/EventManager',$eventManager]
59
+                ['config', $config],
60
+                ['ModuleManager', $moduleManager],
61
+                ['repositories', $repositories],
62
+                ['Core/EventManager', $eventManager]
63 63
             ])
64 64
         ;
65 65
 
@@ -73,9 +73,9 @@  discard block
 block discarded – undo
73 73
     public function invokeTestProvider()
74 74
     {
75 75
         return [
76
-            ['Core/Index',IndexController::class],
77
-            ['Core/File',FileController::class],
78
-            ['Core/Content',ContentController::class],
76
+            ['Core/Index', IndexController::class],
77
+            ['Core/File', FileController::class],
78
+            ['Core/Content', ContentController::class],
79 79
         ];
80 80
     }
81 81
 
Please login to merge, or discard this patch.
Core/test/CoreTest/Factory/Listener/DeleteImageSetListenerFactoryTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
         '@testCreateService' => ['mock' => ['__invoke' => ['@with' => 'getCreateServiceInvokationArgs', 'count' => 1]]],
40 40
     ];
41 41
 
42
-    private $inheritance = [ FactoryInterface::class ];
42
+    private $inheritance = [FactoryInterface::class];
43 43
 
44 44
     private function getCreateServiceInvokationArgs()
45 45
     {
Please login to merge, or discard this patch.
module/Core/test/CoreTest/Factory/OptionsAbstractFactoryTest.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -56,10 +56,10 @@  discard block
 block discarded – undo
56 56
         ];
57 57
 
58 58
         return [
59
-            [ [], 'testnameone', 'Test/Name.One', false ],
60
-            [ $cfg1, 'testnametwo', 'Test.Name/Two', true ],
61
-            [ $cfg1, 'othername', '', false ],
62
-            [ $cfg1, 'nonexistant', 'Non.Existant', false ],
59
+            [[], 'testnameone', 'Test/Name.One', false],
60
+            [$cfg1, 'testnametwo', 'Test.Name/Two', true],
61
+            [$cfg1, 'othername', '', false],
62
+            [$cfg1, 'nonexistant', 'Non.Existant', false],
63 63
         ];
64 64
     }
65 65
 
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
 
80 80
         $services = $this->getServiceLocatorMock($optionsConfig);
81 81
 
82
-        $method = "assert" . ($expected ? 'True' : 'False');
82
+        $method = "assert".($expected ? 'True' : 'False');
83 83
         $this->$method($target->canCreateServiceWithName($services, $name, $requestedName));
84 84
     }
85 85
 
@@ -91,10 +91,10 @@  discard block
 block discarded – undo
91 91
         ];
92 92
 
93 93
         return [
94
-            [ [], 'Test/Name.One', false ],
95
-            [ $cfg1, 'Test.Name/Two', true ],
96
-            [ $cfg1, 'othername', true ],
97
-            [ $cfg1, 'Non.Existant', false ],
94
+            [[], 'Test/Name.One', false],
95
+            [$cfg1, 'Test.Name/Two', true],
96
+            [$cfg1, 'othername', true],
97
+            [$cfg1, 'Non.Existant', false],
98 98
         ];
99 99
     }
100 100
 
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
 
144 144
         $services = $this->getServiceLocatorMock([
145 145
             'TestOption' => [
146
-                'class' => __NAMESPACE__ . '\SimpleOptionsMock',
146
+                'class' => __NAMESPACE__.'\SimpleOptionsMock',
147 147
                 'mode' => 'invalid',
148 148
             ]
149 149
         ]);
@@ -158,11 +158,11 @@  discard block
 block discarded – undo
158 158
      */
159 159
     public function testCreatesSimpleOptionsInstance()
160 160
     {
161
-        $optionsMockClass = __NAMESPACE__ . '\SimpleOptionsMock';
161
+        $optionsMockClass = __NAMESPACE__.'\SimpleOptionsMock';
162 162
         $cfg = [
163 163
             'SimpleOptions' => [
164 164
                 'class' => $optionsMockClass,
165
-                'options' => [ 'one' => 'three' ]
165
+                'options' => ['one' => 'three']
166 166
             ]
167 167
         ];
168 168
 
@@ -203,8 +203,8 @@  discard block
 block discarded – undo
203 203
      */
204 204
     public function testCreateNestedOptionsInstance()
205 205
     {
206
-        $nestedOptionsMockClass = __NAMESPACE__ . '\NestedOptionsMock';
207
-        $simpleOptionsMockClass = __NAMESPACE__ . '\SimpleOptionsMock';
206
+        $nestedOptionsMockClass = __NAMESPACE__.'\NestedOptionsMock';
207
+        $simpleOptionsMockClass = __NAMESPACE__.'\SimpleOptionsMock';
208 208
 
209 209
         $cfg = [
210 210
             'NestedOptions' => [
@@ -212,9 +212,9 @@  discard block
 block discarded – undo
212 212
                 'mode' => OptionsAbstractFactory::MODE_NESTED,
213 213
                 'options' => [
214 214
                     'skalar' => 'itsworking',
215
-                    'array' => [ 'its' => 'working' ],
216
-                    'opt1' => [ '__class__' => $simpleOptionsMockClass ],
217
-                    'opt2' => [ '__class__' => $simpleOptionsMockClass, 'two' => 'four' ],
215
+                    'array' => ['its' => 'working'],
216
+                    'opt1' => ['__class__' => $simpleOptionsMockClass],
217
+                    'opt2' => ['__class__' => $simpleOptionsMockClass, 'two' => 'four'],
218 218
                 ],
219 219
             ],
220 220
         ];
@@ -228,14 +228,14 @@  discard block
 block discarded – undo
228 228
 
229 229
         $this->assertInstanceOf($nestedOptionsMockClass, $options);
230 230
         $this->assertEquals('itsworking', $options->getSkalar());
231
-        $this->assertEquals([ 'its' => 'working' ], $options->getArray());
231
+        $this->assertEquals(['its' => 'working'], $options->getArray());
232 232
         $this->assertEquals('One', $options->getOpt1()->getOne());
233 233
         $this->assertEquals('four', $options->getOpt2()->getTwo());
234 234
     }
235 235
 
236 236
     protected function getServiceLocatorMock($optionsConfig = [])
237 237
     {
238
-        $optionsConfig = [ 'options' => $optionsConfig ];
238
+        $optionsConfig = ['options' => $optionsConfig];
239 239
         $services = $this->getMockBuilder('Zend\ServiceManager\ServiceManager')->disableOriginalConstructor()->getMock();
240 240
 
241 241
         $services->expects($this->once())->method('get')->with('config')->willReturn($optionsConfig);
@@ -247,7 +247,7 @@  discard block
 block discarded – undo
247 247
 class SimpleOptionsMock extends AbstractOptions
248 248
 {
249 249
     protected $one = "One";
250
-    protected $two= "Two";
250
+    protected $two = "Two";
251 251
 
252 252
     /**
253 253
      * @param string $one
Please login to merge, or discard this patch.
module/Core/test/CoreTest/Factory/Service/ImagineFactoryTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
         '@testCreateService' => ['mock' => ['__invoke' => ['@with' => 'getInvokationMockArgs', 'count' => 1]]],
42 42
     ];
43 43
 
44
-    private $inheritance = [ FactoryInterface::class ];
44
+    private $inheritance = [FactoryInterface::class];
45 45
 
46 46
     private function getInvokationMockArgs()
47 47
     {
@@ -88,6 +88,6 @@  discard block
 block discarded – undo
88 88
             }
89 89
         }
90 90
 
91
-        $this->fail('Imagine instance creation for ' .$lib . ' failed.');
91
+        $this->fail('Imagine instance creation for '.$lib.' failed.');
92 92
     }
93 93
 }
Please login to merge, or discard this patch.
module/Core/test/CoreTest/Factory/Form/Tree/SelectFactoryTest.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
         ],
52 52
     ];
53 53
 
54
-    private $inheritance = [ FactoryInterface::class];
54
+    private $inheritance = [FactoryInterface::class];
55 55
 
56 56
     public function testSetCreationOptions()
57 57
     {
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
         $services = new ServiceManager();
70 70
         $forms    = new FormElementManagerV3Polyfill($services);
71 71
 
72
-        $options = [ 'test' => 'work?' ];
72
+        $options = ['test' => 'work?'];
73 73
         $this->target->setCreationOptions($options);
74 74
 
75 75
         $this->target
@@ -86,11 +86,11 @@  discard block
 block discarded – undo
86 86
     public function provideMissingOptions()
87 87
     {
88 88
         return [
89
-            [ null ],
90
-            [ [] ],
91
-            [ ['tree' => ['value' => 'test']] ],
92
-            [ ['tree' => ['entity' => 'test']] ],
93
-            [ ['tree' => ['name' => 'test']] ],
89
+            [null],
90
+            [[]],
91
+            [['tree' => ['value' => 'test']]],
92
+            [['tree' => ['entity' => 'test']]],
93
+            [['tree' => ['name' => 'test']]],
94 94
         ];
95 95
     }
96 96
 
@@ -122,10 +122,10 @@  discard block
 block discarded – undo
122 122
         $this->expectException(\RuntimeException::class);
123 123
         $this->expectExceptionMessage('Tree root not found');
124 124
 
125
-        $this->target->__invoke($services, '', ['tree' => [ 'entity' => 'testEntityRepository', 'value' => 'test']]);
125
+        $this->target->__invoke($services, '', ['tree' => ['entity' => 'testEntityRepository', 'value' => 'test']]);
126 126
     }
127 127
 
128
-    private function getServiceContainer($criteria, $root=null)
128
+    private function getServiceContainer($criteria, $root = null)
129 129
     {
130 130
         if (null === $root) {
131 131
             $root = new Node('Test');
@@ -188,9 +188,9 @@  discard block
 block discarded – undo
188 188
         $root3 = $this->createRoot('root', ['child1' => ['gChild11', 'gChild12']]);
189 189
 
190 190
         return [
191
-            [ $root1, [], ['child1' => ['label' => 'child1', 'options' => ['child1-gchild11' => 'gChild11', 'child1-gchild12' => 'gChild12']]]],
192
-            [ $root2, ['use_root_item' => true], ['root' => ['label' => 'root', 'options' => ['child1' => ['label' => 'child1', 'options' => ['child1-gchild11' => 'gChild11', 'child1-gchild12' => 'gChild12']]]]]],
193
-            [ $root3, ['allow_select_nodes' => true], ['child1-group' => ['label' => 'child1', 'options' => ['child1' => 'child1', 'child1-gchild11' => 'gChild11', 'child1-gchild12' => 'gChild12']]] ]
191
+            [$root1, [], ['child1' => ['label' => 'child1', 'options' => ['child1-gchild11' => 'gChild11', 'child1-gchild12' => 'gChild12']]]],
192
+            [$root2, ['use_root_item' => true], ['root' => ['label' => 'root', 'options' => ['child1' => ['label' => 'child1', 'options' => ['child1-gchild11' => 'gChild11', 'child1-gchild12' => 'gChild12']]]]]],
193
+            [$root3, ['allow_select_nodes' => true], ['child1-group' => ['label' => 'child1', 'options' => ['child1' => 'child1', 'child1-gchild11' => 'gChild11', 'child1-gchild12' => 'gChild12']]]]
194 194
         ];
195 195
     }
196 196
 
Please login to merge, or discard this patch.