/** * Execute handler * * @param FixtureInterface $fixture * @return mixed */ public function persist(FixtureInterface $fixture = null) { /** @var \Magento\Customer\Test\Fixture\Customer $fixture */ $address = $fixture->getDefaultBillingAddress(); $fields = $this->prepareData($address->getData('fields')); $url = $_ENV['app_frontend_url'] . $this->saveUrl; $curl = $this->saveCustomer($fixture); $fields['form_key'] = $this->formKey; $curl->write(CurlInterface::POST, $url, '1.0', array(), $fields); $response = $curl->read(); $curl->close(); return $response; }