@@ -52,8 +52,8 @@ discard block |
||
52 | 52 | public function providerRenderMode() |
53 | 53 | { |
54 | 54 | return [ |
55 | - [SummaryFormInterface::RENDER_FORM,SummaryFormInterface::RENDER_FORM], |
|
56 | - [SummaryFormInterface::RENDER_SUMMARY,SummaryFormInterface::RENDER_SUMMARY], |
|
55 | + [SummaryFormInterface::RENDER_FORM, SummaryFormInterface::RENDER_FORM], |
|
56 | + [SummaryFormInterface::RENDER_SUMMARY, SummaryFormInterface::RENDER_SUMMARY], |
|
57 | 57 | [SummaryFormInterface::RENDER_ALL, SummaryFormInterface::RENDER_ALL], |
58 | 58 | ]; |
59 | 59 | } |
@@ -75,8 +75,8 @@ discard block |
||
75 | 75 | public function providerDisplayMode() |
76 | 76 | { |
77 | 77 | return [ |
78 | - [SummaryFormInterface::DISPLAY_FORM,SummaryFormInterface::DISPLAY_FORM], |
|
79 | - [SummaryFormInterface::DISPLAY_SUMMARY,SummaryFormInterface::DISPLAY_SUMMARY], |
|
78 | + [SummaryFormInterface::DISPLAY_FORM, SummaryFormInterface::DISPLAY_FORM], |
|
79 | + [SummaryFormInterface::DISPLAY_SUMMARY, SummaryFormInterface::DISPLAY_SUMMARY], |
|
80 | 80 | ]; |
81 | 81 | } |
82 | 82 | |
@@ -94,7 +94,7 @@ discard block |
||
94 | 94 | */ |
95 | 95 | public function testSetOptions($input, $expected) |
96 | 96 | { |
97 | - $this->target->setOptions(['display_mode' => $input ]); |
|
97 | + $this->target->setOptions(['display_mode' => $input]); |
|
98 | 98 | $this->assertSame($this->target->getDisplayMode(), $expected); |
99 | 99 | } |
100 | 100 | } |
@@ -81,8 +81,8 @@ |
||
81 | 81 | } |
82 | 82 | |
83 | 83 | /** |
84 | - * @todo |
|
85 | - */ |
|
84 | + * @todo |
|
85 | + */ |
|
86 | 86 | /* |
87 | 87 | public function testIsValid() |
88 | 88 | { |
@@ -32,27 +32,27 @@ |
||
32 | 32 | public function propertiesProvider() |
33 | 33 | { |
34 | 34 | return [ |
35 | - [ 'summaryEmpty', [ |
|
35 | + ['summaryEmpty', [ |
|
36 | 36 | 'ignore_setter' => true, |
37 | - 'pre' => function () { |
|
37 | + 'pre' => function() { |
|
38 | 38 | $this->target->add(['name' => 'test', 'type' => 'text', 'attributes' => ['value'=>'test']]); |
39 | 39 | }, |
40 | 40 | 'value' => false, |
41 | 41 | 'getter_method' => 'is*' |
42 | 42 | ]], |
43 | - [ 'summaryEmpty', [ |
|
43 | + ['summaryEmpty', [ |
|
44 | 44 | 'ignore_setter' => true, |
45 | - 'pre' => function () { |
|
45 | + 'pre' => function() { |
|
46 | 46 | $this->target->add(['name' => 'test', 'type' => 'text']); |
47 | 47 | }, |
48 | 48 | 'value' => true, |
49 | 49 | 'getter_method' => 'is*', |
50 | 50 | ]], |
51 | - [ 'emptySummaryNotice', [ |
|
51 | + ['emptySummaryNotice', [ |
|
52 | 52 | 'value' => 'notice', |
53 | 53 | 'default' => null |
54 | 54 | ]], |
55 | - [ 'emptySummaryNotice', [ |
|
55 | + ['emptySummaryNotice', [ |
|
56 | 56 | 'value' => 'notice', |
57 | 57 | 'default' => 'defaultNotice', |
58 | 58 | ]], |
@@ -126,7 +126,7 @@ discard block |
||
126 | 126 | $this->assertIsString($result); |
127 | 127 | $this->assertStringStartsWith('<input', $result); |
128 | 128 | $this->assertContains('type="file"', $result); |
129 | - $this->assertContains('name="' . $element->getName() . '"', $result); |
|
129 | + $this->assertContains('name="'.$element->getName().'"', $result); |
|
130 | 130 | } |
131 | 131 | |
132 | 132 | /** |
@@ -223,7 +223,7 @@ discard block |
||
223 | 223 | $fileUploadHelper->expects($this->once()) |
224 | 224 | ->method('renderMarkup') |
225 | 225 | ->with($this->equalTo($element)) |
226 | - ->willReturn($markupOutput . $fileElementPlaceholder); |
|
226 | + ->willReturn($markupOutput.$fileElementPlaceholder); |
|
227 | 227 | $fileUploadHelper->expects($this->once()) |
228 | 228 | ->method('renderFileElement') |
229 | 229 | ->with($this->equalTo($element)) |
@@ -33,9 +33,9 @@ |
||
33 | 33 | |
34 | 34 | private $target = MetaDataFieldset::class; |
35 | 35 | |
36 | - private $inheritance = [ Fieldset::class ]; |
|
36 | + private $inheritance = [Fieldset::class]; |
|
37 | 37 | |
38 | 38 | private $properties = [ |
39 | - [ 'hydrator', ['default@' => MetaDataHydrator::class, '@value' => EntityHydrator::class]] |
|
39 | + ['hydrator', ['default@' => MetaDataHydrator::class, '@value' => EntityHydrator::class]] |
|
40 | 40 | ]; |
41 | 41 | } |
@@ -94,8 +94,8 @@ discard block |
||
94 | 94 | public function invalidSpecProvider() |
95 | 95 | { |
96 | 96 | return [ |
97 | - [ [ 'invalid' ] ], |
|
98 | - [ [ ['missing one'] ] ] |
|
97 | + [['invalid']], |
|
98 | + [[['missing one']]] |
|
99 | 99 | ]; |
100 | 100 | } |
101 | 101 | |
@@ -154,7 +154,7 @@ discard block |
||
154 | 154 | { |
155 | 155 | use ListenerAggregateTrait; |
156 | 156 | |
157 | - public $testEventsSpec =[]; |
|
157 | + public $testEventsSpec = []; |
|
158 | 158 | |
159 | 159 | protected function eventsProvider() |
160 | 160 | { |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | $this->assertTrue($this->target->getEventCalled, 'No Event was created!'); |
44 | 44 | |
45 | 45 | $this->target->getEventCalled = false; |
46 | - $this->target->triggerUntil(function () { |
|
46 | + $this->target->triggerUntil(function() { |
|
47 | 47 | }, 'test', null, []); |
48 | 48 | $this->assertTrue($this->target->getEventCalled, 'No Event was created (triggerUntil)'); |
49 | 49 | } |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | { |
53 | 53 | $event = new Event(); |
54 | 54 | $this->target->trigger($event); |
55 | - $this->target->triggerUntil(function () { |
|
55 | + $this->target->triggerUntil(function() { |
|
56 | 56 | }, $event); |
57 | 57 | |
58 | 58 | $this->assertFalse($this->target->getEventCalled, 'An event was created!'); |
@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | public function testCallbackIsPassedAlong() |
62 | 62 | { |
63 | 63 | $event = new Event(); |
64 | - $callback = function () { |
|
64 | + $callback = function() { |
|
65 | 65 | }; |
66 | 66 | $this->target->triggerUntil($callback, $event); |
67 | 67 |
@@ -39,18 +39,18 @@ discard block |
||
39 | 39 | private $target = [ |
40 | 40 | AjaxUrl::class, |
41 | 41 | [self::BASEPATH], |
42 | - '@testInheritance' => [ 'as_reflection' => true ], |
|
42 | + '@testInheritance' => ['as_reflection' => true], |
|
43 | 43 | '@testConstruction' => false, |
44 | 44 | ]; |
45 | 45 | |
46 | - private $inheritance = [ AbstractHelper::class ]; |
|
46 | + private $inheritance = [AbstractHelper::class]; |
|
47 | 47 | |
48 | 48 | public function testConstruction() |
49 | 49 | { |
50 | 50 | $basepath = '/test/path/no/slash'; |
51 | 51 | $target = new AjaxUrl($basepath); |
52 | 52 | |
53 | - $this->assertAttributeSame($basepath . '/', 'basePath', $target); |
|
53 | + $this->assertAttributeSame($basepath.'/', 'basePath', $target); |
|
54 | 54 | |
55 | 55 | $basepath = '/test/path/slash/'; |
56 | 56 | $target = new AjaxUrl($basepath); |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | { |
78 | 78 | $url = $this->target->__invoke(...$args); |
79 | 79 | |
80 | - $expect = self::BASEPATH . $expect; |
|
80 | + $expect = self::BASEPATH.$expect; |
|
81 | 81 | $this->assertEquals($expect, $url); |
82 | 82 | } |
83 | 83 |
@@ -17,7 +17,7 @@ discard block |
||
17 | 17 | |
18 | 18 | class ParamsTest extends TestCase |
19 | 19 | { |
20 | - public function getHelper(MvcEvent $e=null) |
|
20 | + public function getHelper(MvcEvent $e = null) |
|
21 | 21 | { |
22 | 22 | if (null == $e) { |
23 | 23 | $e = new MvcEvent(); |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | |
53 | 53 | public function testFromFilesMethod() |
54 | 54 | { |
55 | - $_FILES=array( |
|
55 | + $_FILES = array( |
|
56 | 56 | 'testFile1' => array( |
57 | 57 | 'name' => 'testfile1.txt', |
58 | 58 | 'type' => 'text/plain', |
@@ -76,7 +76,7 @@ |
||
76 | 76 | public function testFromHeaderMethod() |
77 | 77 | { |
78 | 78 | $headers = "X-Test-Header-1: Header1Value\r\n" |
79 | - . "X-Test-Header-2: Header2Value\r\n"; |
|
79 | + . "X-Test-Header-2: Header2Value\r\n"; |
|
80 | 80 | |
81 | 81 | $r = new Request(); |
82 | 82 | $r->setHeaders(\Laminas\Http\Headers::fromString($headers)); |
@@ -282,10 +282,10 @@ |
||
282 | 282 | 'return' => isset($methodSpec['@return']) |
283 | 283 | ? $call((array) $methodSpec['@return']) |
284 | 284 | : ( |
285 | - isset($methodSpec['return']) |
|
285 | + isset($methodSpec['return']) |
|
286 | 286 | ? ('__self__' === $methodSpec['return'] ? $this->returnSelf() : $this->returnValue($methodSpec['return'])) |
287 | 287 | : null |
288 | - ), |
|
288 | + ), |
|
289 | 289 | ]; |
290 | 290 | } |
291 | 291 | } |
@@ -132,8 +132,8 @@ discard block |
||
132 | 132 | $testName = array_shift($testNameParts); |
133 | 133 | $testSet = trim(array_pop($testNameParts), '"'); |
134 | 134 | |
135 | - $testNameKey = '@' . $testName; |
|
136 | - $testNameSetKey = $testNameKey . '|' . $testSet; |
|
135 | + $testNameKey = '@'.$testName; |
|
136 | + $testNameSetKey = $testNameKey.'|'.$testSet; |
|
137 | 137 | $testSpec = isset($spec[$testNameKey]) ? $spec[$testNameKey] : (isset($spec[$testNameSetKey]) ? $spec[$testNameSetKey] : null); |
138 | 138 | |
139 | 139 | if (null === $testSpec) { |
@@ -142,7 +142,7 @@ discard block |
||
142 | 142 | continue; |
143 | 143 | } |
144 | 144 | |
145 | - if (preg_match('~^' . str_replace('*', '.*', substr($testSpecPattern, 1)) . '~', $testName)) { |
|
145 | + if (preg_match('~^'.str_replace('*', '.*', substr($testSpecPattern, 1)).'~', $testName)) { |
|
146 | 146 | $testSpec = $spec[$testSpecPattern]; |
147 | 147 | break; |
148 | 148 | } |
@@ -159,7 +159,7 @@ discard block |
||
159 | 159 | if (isset($spec[$testSpec])) { |
160 | 160 | $testSpec = $spec[$testSpec]; |
161 | 161 | } elseif (class_exists($testSpec)) { |
162 | - $testSpec = [ $testSpec ]; |
|
162 | + $testSpec = [$testSpec]; |
|
163 | 163 | } else { |
164 | 164 | $this->target = $this->{$testSpec}(); |
165 | 165 | return; |
@@ -190,7 +190,7 @@ discard block |
||
190 | 190 | |
191 | 191 | if (!isset($spec['class'])) { |
192 | 192 | if (!isset($spec[0])) { |
193 | - throw new Exception(__TRAIT__ . ': No target class name specified.'); |
|
193 | + throw new Exception(__TRAIT__.': No target class name specified.'); |
|
194 | 194 | } |
195 | 195 | $spec['class'] = $spec[0]; |
196 | 196 | } |
@@ -251,7 +251,7 @@ discard block |
||
251 | 251 | if (is_string($spec)) { |
252 | 252 | $mock = $this->$spec(); |
253 | 253 | } else { |
254 | - $call = function ($spec) { |
|
254 | + $call = function($spec) { |
|
255 | 255 | $cb = [$this, $spec[0]]; |
256 | 256 | $args = isset($spec[1]) ? (array) $spec[1] : []; |
257 | 257 | |
@@ -259,7 +259,7 @@ discard block |
||
259 | 259 | }; |
260 | 260 | |
261 | 261 | $methods = []; |
262 | - $methodMocks = []; |
|
262 | + $methodMocks = []; |
|
263 | 263 | |
264 | 264 | if (is_array($spec)) { |
265 | 265 | foreach ($spec as $method => $methodSpec) { |