Completed
Push — master ( eb1cb8...a47bac )
by Aimeos
02:06
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/src/Controller/Frontend/Common/Factory/Iface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,5 +27,5 @@
 block discarded – undo
27 27
 	 * @param string|null $name Name of the controller implementation (Default if null)
28 28
 	 * @return \Aimeos\Controller\Frontend\Common\Iface Controller object
29 29
 	 */
30
-	public static function createController( \Aimeos\MShop\Context\Item\Iface $context, $name = null );
30
+	public static function createController(\Aimeos\MShop\Context\Item\Iface $context, $name = null);
31 31
 }
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/Basket/Factory.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
 	 * @param string|null $name Name of the controller implementaton (default: "Standard")
30 30
 	 * @return \Aimeos\Controller\Frontend\Basket\Iface Controller object
31 31
 	 */
32
-	public static function createController( \Aimeos\MShop\Context\Item\Iface $context, $name = null )
32
+	public static function createController(\Aimeos\MShop\Context\Item\Iface $context, $name = null)
33 33
 	{
34 34
 		/** controller/frontend/basket/name
35 35
 		 * Class name of the used basket frontend controller implementation
@@ -64,20 +64,20 @@  discard block
 block discarded – undo
64 64
 		 * @since 2014.03
65 65
 		 * @category Developer
66 66
 		 */
67
-		if( $name === null ) {
68
-			$name = $context->getConfig()->get( 'controller/frontend/basket/name', 'Standard' );
67
+		if ($name === null) {
68
+			$name = $context->getConfig()->get('controller/frontend/basket/name', 'Standard');
69 69
 		}
70 70
 
71
-		if( ctype_alnum( $name ) === false )
71
+		if (ctype_alnum($name) === false)
72 72
 		{
73
-			$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Frontend\\Basket\\' . $name : '<not a string>';
74
-			throw new \Aimeos\Controller\Frontend\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
73
+			$classname = is_string($name) ? '\\Aimeos\\Controller\\Frontend\\Basket\\' . $name : '<not a string>';
74
+			throw new \Aimeos\Controller\Frontend\Exception(sprintf('Invalid characters in class name "%1$s"', $classname));
75 75
 		}
76 76
 
77 77
 		$iface = '\\Aimeos\\Controller\\Frontend\\Basket\\Iface';
78 78
 		$classname = '\\Aimeos\\Controller\\Frontend\\Basket\\' . $name;
79 79
 
80
-		$manager = self::createControllerBase( $context, $classname, $iface );
80
+		$manager = self::createControllerBase($context, $classname, $iface);
81 81
 
82 82
 		/** controller/frontend/basket/decorators/excludes
83 83
 		 * Excludes decorators added by the "common" option from the basket frontend controllers
@@ -153,7 +153,7 @@  discard block
 block discarded – undo
153 153
 		 * @see controller/frontend/basket/decorators/excludes
154 154
 		 * @see controller/frontend/basket/decorators/global
155 155
 		 */
156
-		return self::addControllerDecorators( $context, $manager, 'basket' );
156
+		return self::addControllerDecorators($context, $manager, 'basket');
157 157
 	}
158 158
 
159 159
 }
Please login to merge, or discard this patch.
controller/frontend/src/Controller/Frontend/Order/Factory.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
 	 * @param string|null $name Name of the controller implementaton (default: "Standard")
30 30
 	 * @return \Aimeos\Controller\Frontend\Order\Iface Controller object
31 31
 	 */
32
-	public static function createController( \Aimeos\MShop\Context\Item\Iface $context, $name = null )
32
+	public static function createController(\Aimeos\MShop\Context\Item\Iface $context, $name = null)
33 33
 	{
34 34
 		/** controller/frontend/order/name
35 35
 		 * Class name of the used order frontend controller implementation
@@ -64,19 +64,19 @@  discard block
 block discarded – undo
64 64
 		 * @since 2014.03
65 65
 		 * @category Developer
66 66
 		 */
67
-		if( $name === null ) {
68
-			$name = $context->getConfig()->get( 'controller/frontend/order/name', 'Standard' );
67
+		if ($name === null) {
68
+			$name = $context->getConfig()->get('controller/frontend/order/name', 'Standard');
69 69
 		}
70 70
 
71
-		if( ctype_alnum( $name ) === false ) {
72
-			$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Frontend\\Order\\' . $name : '<not a string>';
73
-			throw new \Aimeos\Controller\Frontend\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
71
+		if (ctype_alnum($name) === false) {
72
+			$classname = is_string($name) ? '\\Aimeos\\Controller\\Frontend\\Order\\' . $name : '<not a string>';
73
+			throw new \Aimeos\Controller\Frontend\Exception(sprintf('Invalid characters in class name "%1$s"', $classname));
74 74
 		}
75 75
 
76 76
 		$iface = '\\Aimeos\\Controller\\Frontend\\Order\\Iface';
77 77
 		$classname = '\\Aimeos\\Controller\\Frontend\\Order\\' . $name;
78 78
 
79
-		$manager = self::createControllerBase( $context, $classname, $iface );
79
+		$manager = self::createControllerBase($context, $classname, $iface);
80 80
 
81 81
 		/** controller/frontend/order/decorators/excludes
82 82
 		 * Excludes decorators added by the "common" option from the order frontend controllers
@@ -152,6 +152,6 @@  discard block
 block discarded – undo
152 152
 		 * @see controller/frontend/order/decorators/excludes
153 153
 		 * @see controller/frontend/order/decorators/global
154 154
 		 */
155
-		return self::addControllerDecorators( $context, $manager, 'order' );
155
+		return self::addControllerDecorators($context, $manager, 'order');
156 156
 	}
157 157
 }
Please login to merge, or discard this patch.