public function testOfeditAddress() { $this->markTestIncomplete(); $addressId = ''; $addressChange = CustomerChangeAddressAction::ofAddressIdAndAddress($addressId); $address = Address::fromArray(['title' => 'mr', 'salutation' => 'mr', 'firstName' => 'Piet', 'lastName' => 'Fiets', 'email' => '*****@*****.**', 'streetName' => 'Akelei', 'streetNumber' => '23', 'building' => 'a', 'Apartment' => 'c', 'postalCode' => '7676dc', 'city' => 'westerhaar', 'country' => 'netherlands', 'region' => 'drenthe', 'state' => 'honkie kong', 'POBox' => '49824', 'AdditionalAddressInfo' => 'null', 'AdditionalStreetInfo' => 'null', 'phone' => '0546659948', 'mobile' => '0620923399', 'department' => '1']); // $userAddress = User }
public function setAddresses($locale, Customer $customer, Address $address, $addressId) { $client = $this->getClient(); $request = CustomerUpdateRequest::ofIdAndVersion($customer->getId(), $customer->getVersion()); $request->addAction(CustomerChangeAddressAction::ofAddressIdAndAddress($addressId, $address)); $response = $request->executeWithClient($client); $customer = $request->mapFromResponse($response, $this->getMapper($locale)); return $customer; }