@@ -20,11 +20,11 @@ |
||
20 | 20 | ->getMockForAbstractClass(); |
21 | 21 | |
22 | 22 | $container = $this->getMockBuilder(\Interop\Container\ContainerInterface::class) |
23 | - ->setMethods(['get']) |
|
23 | + ->setMethods([ 'get' ]) |
|
24 | 24 | ->getMockForAbstractClass(); |
25 | 25 | $container->expects(static::at(0)) |
26 | 26 | ->method('get') |
27 | - ->will(static::returnValue(['upload' => ['public_path' => 'test', 'non_public_path' => 'test']])); |
|
27 | + ->will(static::returnValue([ 'upload' => [ 'public_path' => 'test', 'non_public_path' => 'test' ] ])); |
|
28 | 28 | $container->expects(static::at(1)) |
29 | 29 | ->method('get') |
30 | 30 | ->will(static::returnValue($articleMapper)); |
@@ -20,11 +20,11 @@ |
||
20 | 20 | ->getMockForAbstractClass(); |
21 | 21 | |
22 | 22 | $container = $this->getMockBuilder(\Interop\Container\ContainerInterface::class) |
23 | - ->setMethods(['get']) |
|
23 | + ->setMethods([ 'get' ]) |
|
24 | 24 | ->getMockForAbstractClass(); |
25 | 25 | $container->expects(static::at(0)) |
26 | 26 | ->method('get') |
27 | - ->will(static::returnValue(['upload' => ['public_path' => 'test', 'non_public_path' => 'test']])); |
|
27 | + ->will(static::returnValue([ 'upload' => [ 'public_path' => 'test', 'non_public_path' => 'test' ] ])); |
|
28 | 28 | $container->expects(static::at(1)) |
29 | 29 | ->method('get') |
30 | 30 | ->will(static::returnValue($articleMapper)); |
@@ -10,7 +10,7 @@ |
||
10 | 10 | ->disableOriginalConstructor() |
11 | 11 | ->getMockForAbstractClass(); |
12 | 12 | $container = $this->getMockBuilder(\Interop\Container\ContainerInterface::class) |
13 | - ->setMethods(['get']) |
|
13 | + ->setMethods([ 'get' ]) |
|
14 | 14 | ->getMockForAbstractClass(); |
15 | 15 | $container->expects(static::at(0)) |
16 | 16 | ->method('get') |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | namespace Category\Factory\Service; |
5 | 5 | |
@@ -20,8 +20,8 @@ discard block |
||
20 | 20 | */ |
21 | 21 | public function __invoke(ContainerInterface $container): CategoryService |
22 | 22 | { |
23 | - $config = $container->get('config')['upload']; |
|
24 | - $upload = new Upload($config['public_path'], $config['non_public_path']); |
|
23 | + $config = $container->get('config')[ 'upload' ]; |
|
24 | + $upload = new Upload($config[ 'public_path' ], $config[ 'non_public_path' ]); |
|
25 | 25 | |
26 | 26 | return new CategoryService( |
27 | 27 | $container->get(CategoryMapper::class), |
@@ -29,16 +29,16 @@ |
||
29 | 29 | |
30 | 30 | public function getHeaderMenu() |
31 | 31 | { |
32 | - return $this->menuService->getNestedAll(true, ['is_in_header' => true]); |
|
32 | + return $this->menuService->getNestedAll(true, [ 'is_in_header' => true ]); |
|
33 | 33 | } |
34 | 34 | |
35 | 35 | public function getFooterMenu() |
36 | 36 | { |
37 | - return $this->menuService->getNestedAll(true, ['is_in_footer' => true]); |
|
37 | + return $this->menuService->getNestedAll(true, [ 'is_in_footer' => true ]); |
|
38 | 38 | } |
39 | 39 | |
40 | 40 | public function getSideMenu() |
41 | 41 | { |
42 | - return $this->menuService->getNestedAll(true, ['is_in_side' => true]); |
|
42 | + return $this->menuService->getNestedAll(true, [ 'is_in_side' => true ]); |
|
43 | 43 | } |
44 | 44 | } |
@@ -16,26 +16,26 @@ |
||
16 | 16 | public function testForSelectShouldReturnArray() |
17 | 17 | { |
18 | 18 | $postService = $this->getMockBuilder('Article\Service\PostService') |
19 | - ->setMethods(['getForSelect']) |
|
19 | + ->setMethods([ 'getForSelect' ]) |
|
20 | 20 | ->disableOriginalConstructor() |
21 | 21 | ->getMockForAbstractClass(); |
22 | 22 | $postService->expects(static::once()) |
23 | 23 | ->method('getForSelect') |
24 | - ->willReturn([]); |
|
24 | + ->willReturn([ ]); |
|
25 | 25 | $postHelper = new \Article\View\Helper\PostHelper($postService); |
26 | - static::assertSame([], $postHelper->forSelect()); |
|
26 | + static::assertSame([ ], $postHelper->forSelect()); |
|
27 | 27 | } |
28 | 28 | |
29 | 29 | public function testForWebShouldReturnArray() |
30 | 30 | { |
31 | 31 | $postService = $this->getMockBuilder('Article\Service\PostService') |
32 | - ->setMethods(['getLatestWeb']) |
|
32 | + ->setMethods([ 'getLatestWeb' ]) |
|
33 | 33 | ->disableOriginalConstructor() |
34 | 34 | ->getMockForAbstractClass(); |
35 | 35 | $postService->expects(static::once()) |
36 | 36 | ->method('getLatestWeb') |
37 | - ->willReturn([]); |
|
37 | + ->willReturn([ ]); |
|
38 | 38 | $postHelper = new \Article\View\Helper\PostHelper($postService); |
39 | - static::assertSame([], $postHelper->forWeb()); |
|
39 | + static::assertSame([ ], $postHelper->forWeb()); |
|
40 | 40 | } |
41 | 41 | } |
@@ -16,13 +16,13 @@ |
||
16 | 16 | public function testGetLatestShouldReturnArray() |
17 | 17 | { |
18 | 18 | $videoService = $this->getMockBuilder('Article\Service\VideoService') |
19 | - ->setMethods(['fetchLatest']) |
|
19 | + ->setMethods([ 'fetchLatest' ]) |
|
20 | 20 | ->disableOriginalConstructor() |
21 | 21 | ->getMockForAbstractClass(); |
22 | 22 | $videoService->expects(static::once()) |
23 | 23 | ->method('fetchLatest') |
24 | - ->willReturn([]); |
|
24 | + ->willReturn([ ]); |
|
25 | 25 | $videoHelper = new \Article\View\Helper\VideoHelper($videoService); |
26 | - static::assertSame([], $videoHelper->getLatest()); |
|
26 | + static::assertSame([ ], $videoHelper->getLatest()); |
|
27 | 27 | } |
28 | 28 | } |
@@ -16,13 +16,13 @@ |
||
16 | 16 | public function testAllShouldReturnArray() |
17 | 17 | { |
18 | 18 | $eventService = $this->getMockBuilder('Article\Service\EventService') |
19 | - ->setMethods(['fetchLatest']) |
|
19 | + ->setMethods([ 'fetchLatest' ]) |
|
20 | 20 | ->disableOriginalConstructor() |
21 | 21 | ->getMockForAbstractClass(); |
22 | 22 | $eventService->expects(static::once()) |
23 | 23 | ->method('fetchLatest') |
24 | - ->willReturn([]); |
|
24 | + ->willReturn([ ]); |
|
25 | 25 | $eventHelper = new \Article\View\Helper\EventHelper($eventService); |
26 | - static::assertSame([], $eventHelper->getLatest()); |
|
26 | + static::assertSame([ ], $eventHelper->getLatest()); |
|
27 | 27 | } |
28 | 28 | } |
@@ -10,7 +10,7 @@ |
||
10 | 10 | ->disableOriginalConstructor() |
11 | 11 | ->getMockForAbstractClass(); |
12 | 12 | $container = $this->getMockBuilder(\Interop\Container\ContainerInterface::class) |
13 | - ->setMethods(['get']) |
|
13 | + ->setMethods([ 'get' ]) |
|
14 | 14 | ->getMockForAbstractClass(); |
15 | 15 | $container->expects(static::at(0)) |
16 | 16 | ->method('get') |