Completed
Push — master ( 8086a8...921503 )
by Aimeos
01:52
created
controller/frontend/tests/Controller/Frontend/ExceptionTest.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
 
16 16
 	protected function setUp()
17 17
 	{
18
-		$this->object = new \Aimeos\Controller\Frontend\Exception( 'msg', 1, null, array( 'key' => 'value' ) );
18
+		$this->object = new \Aimeos\Controller\Frontend\Exception('msg', 1, null, array('key' => 'value'));
19 19
 	}
20 20
 
21 21
 
@@ -26,18 +26,18 @@  discard block
 block discarded – undo
26 26
 
27 27
 	public function testGetMessage()
28 28
 	{
29
-		$this->assertEquals( 'msg', $this->object->getMessage() );
29
+		$this->assertEquals('msg', $this->object->getMessage());
30 30
 	}
31 31
 
32 32
 
33 33
 	public function testGetCode()
34 34
 	{
35
-		$this->assertEquals( 1, $this->object->getCode() );
35
+		$this->assertEquals(1, $this->object->getCode());
36 36
 	}
37 37
 
38 38
 
39 39
 	public function testGetErrorList()
40 40
 	{
41
-		$this->assertEquals( array( 'key' => 'value' ), $this->object->getErrorList() );
41
+		$this->assertEquals(array('key' => 'value'), $this->object->getErrorList());
42 42
 	}
43 43
 }
Please login to merge, or discard this patch.
controller/frontend/tests/bootstrap.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -11,22 +11,22 @@
 block discarded – undo
11 11
  * Set error reporting to maximum
12 12
  */
13 13
 error_reporting( -1 );
14
-ini_set( 'display_errors', '1' );
14
+ini_set('display_errors', '1');
15 15
 
16
-date_default_timezone_set( 'UTC' );
16
+date_default_timezone_set('UTC');
17 17
 
18 18
 /**
19 19
  * Set locale settings to reasonable defaults
20 20
  */
21
-setlocale( LC_ALL, 'en_US.UTF-8' );
22
-setlocale( LC_NUMERIC, 'POSIX' );
23
-setlocale( LC_CTYPE, 'en_US.UTF-8' );
24
-setlocale( LC_TIME, 'POSIX' );
21
+setlocale(LC_ALL, 'en_US.UTF-8');
22
+setlocale(LC_NUMERIC, 'POSIX');
23
+setlocale(LC_CTYPE, 'en_US.UTF-8');
24
+setlocale(LC_TIME, 'POSIX');
25 25
 
26 26
 /*
27 27
  * Set include path for tests
28 28
  */
29
-define( 'PATH_TESTS', __DIR__ );
29
+define('PATH_TESTS', __DIR__);
30 30
 
31 31
 require_once 'TestHelperFrontend.php';
32 32
 \TestHelperFrontend::bootstrap();
Please login to merge, or discard this patch.
controller/frontend/tests/Controller/Frontend/Common/Decorator/Example.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
 class Example
22 22
 	implements \Aimeos\Controller\Frontend\Common\Decorator\Iface
23 23
 {
24
-	public function __construct( \Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context )
24
+	public function __construct(\Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context)
25 25
 	{
26 26
 	}
27 27
 }
Please login to merge, or discard this patch.
controller/frontend/src/Controller/Frontend/Common/Decorator/Iface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -26,5 +26,5 @@
 block discarded – undo
26 26
 	 * @param \Aimeos\Controller\Frontend\Iface $controller Controller object
27 27
 	 * @param \Aimeos\MShop\Context\Item\Iface $context Context object with required objects
28 28
 	 */
29
-	public function __construct( \Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context );
29
+	public function __construct(\Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context);
30 30
 }
Please login to merge, or discard this patch.
controller/frontend/src/Controller/Frontend/Common/Iface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -26,6 +26,6 @@
 block discarded – undo
26 26
 	 *
27 27
 	 * @param \Aimeos\MShop\Context\Item\Iface $context MShop context object
28 28
 	 */
29
-	public function __construct( \Aimeos\MShop\Context\Item\Iface $context );
29
+	public function __construct(\Aimeos\MShop\Context\Item\Iface $context);
30 30
 
31 31
 }
Please login to merge, or discard this patch.
controller/frontend/config/controller.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,7 @@
 block discarded – undo
4 4
 	'frontend' => array(
5 5
 		'basket' => array(
6 6
 			'decorators' => array(
7
-				'local' => array( 'Category', 'Bundle', 'Select' ),
7
+				'local' => array('Category', 'Bundle', 'Select'),
8 8
 			),
9 9
 		),
10 10
 	),
Please login to merge, or discard this patch.
controller/frontend/src/Controller/Frontend/Catalog/Decorator/Base.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -278,7 +278,7 @@
 block discarded – undo
278 278
 	/**
279 279
 	 * Returns the frontend controller
280 280
 	 *
281
-	 * @return \Aimeos\Controller\Frontend\Catalog\Iface Frontend controller object
281
+	 * @return \Aimeos\Controller\Frontend\Iface Frontend controller object
282 282
 	 */
283 283
 	protected function getController()
284 284
 	{
Please login to merge, or discard this patch.
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -30,13 +30,13 @@  discard block
 block discarded – undo
30 30
 	 * @param \Aimeos\Controller\Frontend\Iface $controller Controller object
31 31
 	 * @param \Aimeos\MShop\Context\Item\Iface $context Context object with required objects
32 32
 	 */
33
-	public function __construct( \Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context )
33
+	public function __construct(\Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context)
34 34
 	{
35
-		\Aimeos\MW\Common\Base::checkClass( '\\Aimeos\\Controller\\Frontend\\Catalog\\Iface', $controller );
35
+		\Aimeos\MW\Common\Base::checkClass('\\Aimeos\\Controller\\Frontend\\Catalog\\Iface', $controller);
36 36
 
37 37
 		$this->controller = $controller;
38 38
 
39
-		parent::__construct( $context );
39
+		parent::__construct($context);
40 40
 	}
41 41
 
42 42
 
@@ -48,9 +48,9 @@  discard block
 block discarded – undo
48 48
 	 * @return mixed Returns the value of the called method
49 49
 	 * @throws \Aimeos\Controller\Frontend\Exception If method call failed
50 50
 	 */
51
-	public function __call( $name, array $param )
51
+	public function __call($name, array $param)
52 52
 	{
53
-		return @call_user_func_array( array( $this->controller, $name ), $param );
53
+		return @call_user_func_array(array($this->controller, $name), $param);
54 54
 	}
55 55
 
56 56
 
@@ -76,9 +76,9 @@  discard block
 block discarded – undo
76 76
 	 * @return array Associative list of items implementing \Aimeos\MShop\Catalog\Item\Iface with their IDs as keys
77 77
 	 * @since 2017.03
78 78
 	 */
79
-	public function getPath( $id, array $domains = array( 'text', 'media' ) )
79
+	public function getPath($id, array $domains = array('text', 'media'))
80 80
 	{
81
-		return $this->controller->getPath( $id, $domains );
81
+		return $this->controller->getPath($id, $domains);
82 82
 	}
83 83
 
84 84
 
@@ -93,10 +93,10 @@  discard block
 block discarded – undo
93 93
 	 * @return \Aimeos\MShop\Catalog\Item\Iface Catalog node, maybe with children depending on the level constant
94 94
 	 * @since 2017.03
95 95
 	 */
96
-	public function getTree( $id = null, array $domains = array( 'text', 'media' ),
97
-		$level = \Aimeos\MW\Tree\Manager\Base::LEVEL_TREE, \Aimeos\MW\Criteria\Iface $search = null )
96
+	public function getTree($id = null, array $domains = array('text', 'media'),
97
+		$level = \Aimeos\MW\Tree\Manager\Base::LEVEL_TREE, \Aimeos\MW\Criteria\Iface $search = null)
98 98
 	{
99
-		return $this->controller->getTree( $id, $domains, $level, $search );
99
+		return $this->controller->getTree($id, $domains, $level, $search);
100 100
 	}
101 101
 
102 102
 
Please login to merge, or discard this patch.
controller/frontend/src/Controller/Frontend/Order/Decorator/Base.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -152,7 +152,7 @@
 block discarded – undo
152 152
 	/**
153 153
 	 * Returns the frontend controller
154 154
 	 *
155
-	 * @return \Aimeos\Controller\Frontend\Order\Iface Frontend controller object
155
+	 * @return \Aimeos\Controller\Frontend\Iface Frontend controller object
156 156
 	 */
157 157
 	protected function getController()
158 158
 	{
Please login to merge, or discard this patch.
Spacing   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -30,13 +30,13 @@  discard block
 block discarded – undo
30 30
 	 * @param \Aimeos\Controller\Frontend\Iface $controller Controller object
31 31
 	 * @param \Aimeos\MShop\Context\Item\Iface $context Context object with required objects
32 32
 	 */
33
-	public function __construct( \Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context )
33
+	public function __construct(\Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context)
34 34
 	{
35
-		\Aimeos\MW\Common\Base::checkClass( '\\Aimeos\\Controller\\Frontend\\Order\\Iface', $controller );
35
+		\Aimeos\MW\Common\Base::checkClass('\\Aimeos\\Controller\\Frontend\\Order\\Iface', $controller);
36 36
 
37 37
 		$this->controller = $controller;
38 38
 
39
-		parent::__construct( $context );
39
+		parent::__construct($context);
40 40
 	}
41 41
 
42 42
 
@@ -48,9 +48,9 @@  discard block
 block discarded – undo
48 48
 	 * @return mixed Returns the value of the called method
49 49
 	 * @throws \Aimeos\Controller\Frontend\Exception If method call failed
50 50
 	 */
51
-	public function __call( $name, array $param )
51
+	public function __call($name, array $param)
52 52
 	{
53
-		return @call_user_func_array( array( $this->controller, $name ), $param );
53
+		return @call_user_func_array(array($this->controller, $name), $param);
54 54
 	}
55 55
 
56 56
 
@@ -61,9 +61,9 @@  discard block
 block discarded – undo
61 61
 	 * @param string $type Arbitrary order type (max. eight chars)
62 62
 	 * @return \Aimeos\MShop\Order\Item\Iface Created order object
63 63
 	 */
64
-	public function addItem( $baseId, $type )
64
+	public function addItem($baseId, $type)
65 65
 	{
66
-		return $this->controller->addItem( $baseId, $type );
66
+		return $this->controller->addItem($baseId, $type);
67 67
 	}
68 68
 
69 69
 
@@ -85,9 +85,9 @@  discard block
 block discarded – undo
85 85
 	 * @param boolean $default Use default criteria to limit orders
86 86
 	 * @return \Aimeos\MShop\Order\Item\Iface Order object
87 87
 	 */
88
-	public function getItem( $id, $default = true )
88
+	public function getItem($id, $default = true)
89 89
 	{
90
-		return $this->controller->getItem( $id, $default );
90
+		return $this->controller->getItem($id, $default);
91 91
 	}
92 92
 
93 93
 
@@ -97,9 +97,9 @@  discard block
 block discarded – undo
97 97
 	 * @param \Aimeos\MShop\Order\Item\Iface $item Order object
98 98
 	 * @return \Aimeos\MShop\Order\Item\Iface Saved order item
99 99
 	 */
100
-	public function saveItem( \Aimeos\MShop\Order\Item\Iface $item )
100
+	public function saveItem(\Aimeos\MShop\Order\Item\Iface $item)
101 101
 	{
102
-		return $this->controller->saveItem( $item );
102
+		return $this->controller->saveItem($item);
103 103
 	}
104 104
 
105 105
 
@@ -110,9 +110,9 @@  discard block
 block discarded – undo
110 110
 	 * @param integer &$total|null Variable that will contain the total number of available items
111 111
 	 * @return \Aimeos\MShop\Order\Item\Iface[] Associative list of IDs as keys and order objects as values
112 112
 	 */
113
-	public function searchItems( \Aimeos\MW\Criteria\Iface $filter, &$total = null )
113
+	public function searchItems(\Aimeos\MW\Criteria\Iface $filter, &$total = null)
114 114
 	{
115
-		return $this->controller->searchItems( $filter, $total );
115
+		return $this->controller->searchItems($filter, $total);
116 116
 	}
117 117
 
118 118
 
@@ -135,9 +135,9 @@  discard block
 block discarded – undo
135 135
 	 * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order item object
136 136
 	 * @return void
137 137
 	 */
138
-	public function block( \Aimeos\MShop\Order\Item\Iface $orderItem )
138
+	public function block(\Aimeos\MShop\Order\Item\Iface $orderItem)
139 139
 	{
140
-		$this->getController()->block( $orderItem );
140
+		$this->getController()->block($orderItem);
141 141
 	}
142 142
 
143 143
 
@@ -160,9 +160,9 @@  discard block
 block discarded – undo
160 160
 	 * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order item object
161 161
 	 * @return void
162 162
 	 */
163
-	public function unblock( \Aimeos\MShop\Order\Item\Iface $orderItem )
163
+	public function unblock(\Aimeos\MShop\Order\Item\Iface $orderItem)
164 164
 	{
165
-		$this->getController()->unblock( $orderItem );
165
+		$this->getController()->unblock($orderItem);
166 166
 	}
167 167
 
168 168
 
@@ -181,9 +181,9 @@  discard block
 block discarded – undo
181 181
 	 * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order item object
182 182
 	 * @return void
183 183
 	 */
184
-	public function update( \Aimeos\MShop\Order\Item\Iface $orderItem )
184
+	public function update(\Aimeos\MShop\Order\Item\Iface $orderItem)
185 185
 	{
186
-		$this->getController()->update( $orderItem );
186
+		$this->getController()->update($orderItem);
187 187
 	}
188 188
 
189 189
 
Please login to merge, or discard this patch.
controller/frontend/src/Controller/Frontend/Service/Decorator/Base.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -128,7 +128,7 @@
 block discarded – undo
128 128
 	/**
129 129
 	 * Returns the frontend controller
130 130
 	 *
131
-	 * @return \Aimeos\Controller\Frontend\Service\Iface Frontend controller object
131
+	 * @return \Aimeos\Controller\Frontend\Iface Frontend controller object
132 132
 	 */
133 133
 	protected function getController()
134 134
 	{
Please login to merge, or discard this patch.
Spacing   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -33,13 +33,13 @@  discard block
 block discarded – undo
33 33
 	 * @param \Aimeos\Controller\Frontend\Iface $controller Controller object
34 34
 	 * @param \Aimeos\MShop\Context\Item\Iface $context Context object with required objects
35 35
 	 */
36
-	public function __construct( \Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context )
36
+	public function __construct(\Aimeos\Controller\Frontend\Iface $controller, \Aimeos\MShop\Context\Item\Iface $context)
37 37
 	{
38
-		\Aimeos\MW\Common\Base::checkClass( '\\Aimeos\\Controller\\Frontend\\Service\\Iface', $controller );
38
+		\Aimeos\MW\Common\Base::checkClass('\\Aimeos\\Controller\\Frontend\\Service\\Iface', $controller);
39 39
 
40 40
 		$this->controller = $controller;
41 41
 
42
-		parent::__construct( $context );
42
+		parent::__construct($context);
43 43
 	}
44 44
 
45 45
 
@@ -51,9 +51,9 @@  discard block
 block discarded – undo
51 51
 	 * @return mixed Returns the value of the called method
52 52
 	 * @throws \Aimeos\Controller\Frontend\Exception If method call failed
53 53
 	 */
54
-	public function __call( $name, array $param )
54
+	public function __call($name, array $param)
55 55
 	{
56
-		return @call_user_func_array( array( $this->controller, $name ), $param );
56
+		return @call_user_func_array(array($this->controller, $name), $param);
57 57
 	}
58 58
 
59 59
 
@@ -64,9 +64,9 @@  discard block
 block discarded – undo
64 64
 	 * @param string[] $attributes List of attribute codes as keys and strings entered by the customer as value
65 65
 	 * @return string[] List of attributes codes as keys and error messages as values for invalid or missing values
66 66
 	 */
67
-	public function checkAttributes( $serviceId, array $attributes )
67
+	public function checkAttributes($serviceId, array $attributes)
68 68
 	{
69
-		return $this->controller->checkAttributes( $serviceId, $attributes );
69
+		return $this->controller->checkAttributes($serviceId, $attributes);
70 70
 	}
71 71
 
72 72
 
@@ -77,9 +77,9 @@  discard block
 block discarded – undo
77 77
 	 * @param array $ref List of domains for which the items referenced by the services should be fetched too
78 78
 	 * @return \Aimeos\MShop\Service\Provider\Iface Service provider object
79 79
 	 */
80
-	public function getProvider( $serviceId, $ref = ['media', 'price', 'text'] )
80
+	public function getProvider($serviceId, $ref = ['media', 'price', 'text'])
81 81
 	{
82
-		return $this->controller->getProvider( $serviceId, $ref );
82
+		return $this->controller->getProvider($serviceId, $ref);
83 83
 	}
84 84
 
85 85
 
@@ -90,9 +90,9 @@  discard block
 block discarded – undo
90 90
 	 * @param array $ref List of domains for which the items referenced by the services should be fetched too
91 91
 	 * @return \Aimeos\MShop\Service\Provider\Iface[] List of service IDs as keys and service provider objects as values
92 92
 	 */
93
-	public function getProviders( $type = null, $ref = ['media', 'price', 'text'] )
93
+	public function getProviders($type = null, $ref = ['media', 'price', 'text'])
94 94
 	{
95
-		return $this->controller->getProviders( $type, $ref );
95
+		return $this->controller->getProviders($type, $ref);
96 96
 	}
97 97
 
98 98
 
@@ -107,9 +107,9 @@  discard block
 block discarded – undo
107 107
 	 * @return \Aimeos\MShop\Common\Item\Helper\Form\Iface|null Form object with URL, parameters, etc.
108 108
 	 * 	or null if no form data is required
109 109
 	 */
110
-	public function process( \Aimeos\MShop\Order\Item\Iface $orderItem, $serviceId, array $urls, array $params )
110
+	public function process(\Aimeos\MShop\Order\Item\Iface $orderItem, $serviceId, array $urls, array $params)
111 111
 	{
112
-		return $this->controller->process( $orderItem, $serviceId, $urls, $params );
112
+		return $this->controller->process($orderItem, $serviceId, $urls, $params);
113 113
 	}
114 114
 
115 115
 
@@ -121,9 +121,9 @@  discard block
 block discarded – undo
121 121
 	 * @param string $code Unique code of the service used for the current order
122 122
 	 * @return \Psr\Http\Message\ResponseInterface Response object
123 123
 	 */
124
-	public function updatePush( ServerRequestInterface $request, ResponseInterface $response, $code )
124
+	public function updatePush(ServerRequestInterface $request, ResponseInterface $response, $code)
125 125
 	{
126
-		return $this->controller->updatePush( $request, $response, $code );
126
+		return $this->controller->updatePush($request, $response, $code);
127 127
 	}
128 128
 
129 129
 
@@ -135,9 +135,9 @@  discard block
 block discarded – undo
135 135
 	 * @param string $orderid ID of the order whose payment status should be updated
136 136
 	 * @return \Aimeos\MShop\Order\Item\Iface $orderItem Order item that has been updated
137 137
 	 */
138
-	public function updateSync( ServerRequestInterface $request, $code, $orderid )
138
+	public function updateSync(ServerRequestInterface $request, $code, $orderid)
139 139
 	{
140
-		return $this->controller->updateSync( $request, $code, $orderid );
140
+		return $this->controller->updateSync($request, $code, $orderid);
141 141
 	}
142 142
 
143 143
 
Please login to merge, or discard this patch.