@@ -122,7 +122,7 @@ |
||
122 | 122 | protected function assertWebsitesEquals(array $expectedWebsites) |
123 | 123 | { |
124 | 124 | $websiteEntities = $this->em->getRepository(Website::class)->findBy([], ['originId' => 'ASC']); |
125 | - $websites = array_map(function (Website $item) { |
|
125 | + $websites = array_map(function(Website $item) { |
|
126 | 126 | return [ |
127 | 127 | 'id' => $item->getOriginId(), |
128 | 128 | 'code' => $item->getCode(), |
@@ -131,7 +131,7 @@ |
||
131 | 131 | protected function assertRegionsEquals(array $expectedRegions) |
132 | 132 | { |
133 | 133 | $regionEntities = $this->em->getRepository(Region::class)->findBy([], ['id' => 'ASC']); |
134 | - $regions = array_map(function (Region $item) { |
|
134 | + $regions = array_map(function(Region $item) { |
|
135 | 135 | return [ |
136 | 136 | "combinedCode" => $item->getCombinedCode(), |
137 | 137 | "code" => $item->getCode(), |
@@ -121,7 +121,7 @@ |
||
121 | 121 | protected function assertStoresEquals(array $expectecStores) |
122 | 122 | { |
123 | 123 | $storeEntities = $this->em->getRepository(Store::class)->findBy([], ['originId' => 'ASC']); |
124 | - $stores = array_map(function (Store $item) { |
|
124 | + $stores = array_map(function(Store $item) { |
|
125 | 125 | return [ |
126 | 126 | 'id' => $item->getOriginId(), |
127 | 127 | 'code' => $item->getCode(), |
@@ -174,7 +174,7 @@ discard block |
||
174 | 174 | */ |
175 | 175 | protected function getExpectedResultCallback($firstName, $lastName, $email) |
176 | 176 | { |
177 | - return function () use ($firstName, $lastName, $email) { |
|
177 | + return function() use ($firstName, $lastName, $email) { |
|
178 | 178 | /** |
179 | 179 | * @var $store Store |
180 | 180 | */ |
@@ -230,7 +230,7 @@ discard block |
||
230 | 230 | $order = new Order(); |
231 | 231 | $order->setCustomer($customer); |
232 | 232 | $order->setOriginId(1); |
233 | - $order->setIncrementId((string) rand(1, 1000)); |
|
233 | + $order->setIncrementId((string)rand(1, 1000)); |
|
234 | 234 | $order->setCustomerEmail($email); |
235 | 235 | $order->setCart(new Cart()); |
236 | 236 | $order->setStatus('open'); |
@@ -136,7 +136,7 @@ |
||
136 | 136 | $orderNotesCollection |
137 | 137 | ); |
138 | 138 | |
139 | - $actualOrderNoteIds = $orderNotesCollection->map(function (OrderNote $orderNote) { |
|
139 | + $actualOrderNoteIds = $orderNotesCollection->map(function(OrderNote $orderNote) { |
|
140 | 140 | return $orderNote->getOriginId(); |
141 | 141 | })->toArray(); |
142 | 142 |
@@ -41,7 +41,7 @@ |
||
41 | 41 | |
42 | 42 | $magentoAddressUSAZ = $this->createMagentoAddress($this->regions['US-AZ'], $this->countries['US']); |
43 | 43 | $magentoAddressUSLA = $this->createMagentoAddress($this->regions['US-LA'], $this->countries['US']); |
44 | - $account = $this->createAccount(); |
|
44 | + $account = $this->createAccount(); |
|
45 | 45 | |
46 | 46 | $customer = $this->createCustomer(1, $account, $magentoAddressUSAZ, self::NONE_SHARED_EMAIL); |
47 | 47 | $customer2 = $this->createCustomer(2, $account, $magentoAddressUSLA, self::TEST_SHARED_EMAIL); |
@@ -165,12 +165,12 @@ |
||
165 | 165 | $origin |
166 | 166 | ) { |
167 | 167 | $result = $adminUrl . |
168 | - '/oro_gateway/do?'.$origin.'=' . |
|
169 | - $id . |
|
170 | - '&route=' . $magentoRoute . |
|
171 | - '&workflow=' . $flowName . |
|
172 | - '&success_url=' . urlencode($successUrl) . |
|
173 | - '&error_url=' . urlencode($errorUrl); |
|
168 | + '/oro_gateway/do?'.$origin.'=' . |
|
169 | + $id . |
|
170 | + '&route=' . $magentoRoute . |
|
171 | + '&workflow=' . $flowName . |
|
172 | + '&success_url=' . urlencode($successUrl) . |
|
173 | + '&error_url=' . urlencode($errorUrl); |
|
174 | 174 | |
175 | 175 | $this->transport->expects($this->atLeastOnce())->method('getAdminUrl')->will($this->returnValue($adminUrl)); |
176 | 176 |
@@ -165,7 +165,7 @@ discard block |
||
165 | 165 | $origin |
166 | 166 | ) { |
167 | 167 | $result = $adminUrl . |
168 | - '/oro_gateway/do?'.$origin.'=' . |
|
168 | + '/oro_gateway/do?' . $origin . '=' . |
|
169 | 169 | $id . |
170 | 170 | '&route=' . $magentoRoute . |
171 | 171 | '&workflow=' . $flowName . |
@@ -214,10 +214,10 @@ discard block |
||
214 | 214 | $exception = new ExtensionRequiredException; |
215 | 215 | |
216 | 216 | return [ |
217 | - [144, $successRoute, $errorRoute, $adminUrl, $successUrl, $errorUrl, $flowName, $newOrderRoute, $origin], |
|
217 | + [144, $successRoute, $errorRoute, $adminUrl, $successUrl, $errorUrl, $flowName, $newOrderRoute, $origin], |
|
218 | 218 | [356, $successRoute, $errorRoute, $exception, $successUrl, $errorUrl, $flowName, $checkoutRoute, $origin], |
219 | - [543, $exception, $errorRoute, $adminUrl, $successUrl, $errorUrl, $flowName, $newOrderRoute, $origin], |
|
220 | - [632, $successRoute, $exception, $adminUrl, $successUrl, $errorUrl, $flowName, $newOrderRoute, $origin], |
|
219 | + [543, $exception, $errorRoute, $adminUrl, $successUrl, $errorUrl, $flowName, $newOrderRoute, $origin], |
|
220 | + [632, $successRoute, $exception, $adminUrl, $successUrl, $errorUrl, $flowName, $newOrderRoute, $origin], |
|
221 | 221 | ]; |
222 | 222 | } |
223 | 223 | } |
@@ -34,7 +34,7 @@ |
||
34 | 34 | $this->assertFalse($stateManager->isInState($object->stateField, self::STATE_REQUIRE_ADDRESS)); |
35 | 35 | $this->assertFalse($stateManager->isInState($object->stateField, self::STATE_REQUIRE_INFO)); |
36 | 36 | |
37 | - $stateManager->addState($object, 'stateField', self::STATE_REQUIRE_ADDRESS | self::STATE_REQUIRE_INFO); |
|
37 | + $stateManager->addState($object, 'stateField', self::STATE_REQUIRE_ADDRESS|self::STATE_REQUIRE_INFO); |
|
38 | 38 | $this->assertTrue($stateManager->isInState($object->stateField, self::STATE_REQUIRE_ADDRESS)); |
39 | 39 | $this->assertTrue($stateManager->isInState($object->stateField, self::STATE_REQUIRE_INFO)); |
40 | 40 |
@@ -34,18 +34,18 @@ |
||
34 | 34 | $adminUrl = 'http://localhost/admin'; |
35 | 35 | |
36 | 36 | return [ |
37 | - 'wsdl_url' => ['wsdlUrl', $wsdlUrl, $wsdlUrl], |
|
38 | - 'api_user' => ['apiUser', $apiUser, $apiUser], |
|
39 | - 'api_key' => ['apiKey', $apiKey, $apiKey], |
|
40 | - 'website_id' => ['websiteId', $websiteId, $websiteId], |
|
41 | - 'websites' => ['websites', $websites, $websites], |
|
42 | - 'syncStartDate' => ['syncStartDate', $syncStartDate, $syncStartDate], |
|
43 | - 'syncRange' => ['syncRange', $syncRange, $syncRange], |
|
37 | + 'wsdl_url' => ['wsdlUrl', $wsdlUrl, $wsdlUrl], |
|
38 | + 'api_user' => ['apiUser', $apiUser, $apiUser], |
|
39 | + 'api_key' => ['apiKey', $apiKey, $apiKey], |
|
40 | + 'website_id' => ['websiteId', $websiteId, $websiteId], |
|
41 | + 'websites' => ['websites', $websites, $websites], |
|
42 | + 'syncStartDate' => ['syncStartDate', $syncStartDate, $syncStartDate], |
|
43 | + 'syncRange' => ['syncRange', $syncRange, $syncRange], |
|
44 | 44 | 'is_extension_installed' => ['isExtensionInstalled', $isExtensionInstalled, $isExtensionInstalled], |
45 | - 'guest_customer_sync' => ['guestCustomerSync', $guestCustomerSync, $guestCustomerSync], |
|
46 | - 'admin_url' => ['adminUrl', $adminUrl, $adminUrl], |
|
47 | - 'extension_version' => ['extensionVersion', '1.0.0', '1.0.0'], |
|
48 | - 'magento_version' => ['magentoVersion', '1.0.0', '1.0.0'], |
|
45 | + 'guest_customer_sync' => ['guestCustomerSync', $guestCustomerSync, $guestCustomerSync], |
|
46 | + 'admin_url' => ['adminUrl', $adminUrl, $adminUrl], |
|
47 | + 'extension_version' => ['extensionVersion', '1.0.0', '1.0.0'], |
|
48 | + 'magento_version' => ['magentoVersion', '1.0.0', '1.0.0'], |
|
49 | 49 | 'newsletter_subscriber_synced_to_id' => ['newsletter_subscriber_synced_to_id', 10, 10] |
50 | 50 | ]; |
51 | 51 | } |