/** * Create gift registry entity test. * * @param GiftRegistry $giftRegistry * @param Customer $customer * @return void */ public function test(GiftRegistry $giftRegistry, Customer $customer) { // Steps $this->objectManager->create('Mage\\Customer\\Test\\TestStep\\LoginCustomerOnFrontendStep', ['customer' => $customer])->run(); $this->customerAccountIndex->getAccountNavigationBlock()->openNavigationItem("Gift Registry"); $this->giftRegistryIndex->getGiftRegistryList()->addNew(); $this->giftRegistryAddSelect->getGiftRegistryEditForm()->selectGiftRegistryType($giftRegistry->getTypeId()); $this->giftRegistryEdit->getGiftRegistryEditForm()->fill($giftRegistry); $this->giftRegistryEdit->getGiftRegistryEditForm()->save(); }