From 0b3d320539672d2ef04164ee15724c6e25857bee Mon Sep 17 00:00:00 2001 From: Mykola Palamar Date: Tue, 21 Feb 2017 16:18:59 +0200 Subject: [PATCH] MAGETWO-64796: Added fixture for Customer module with assigned website --- .../Customer/_files/customer_with_website.php | 27 +++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 dev/tests/integration/testsuite/Magento/Customer/_files/customer_with_website.php diff --git a/dev/tests/integration/testsuite/Magento/Customer/_files/customer_with_website.php b/dev/tests/integration/testsuite/Magento/Customer/_files/customer_with_website.php new file mode 100644 index 0000000000000..d39ceb0e15896 --- /dev/null +++ b/dev/tests/integration/testsuite/Magento/Customer/_files/customer_with_website.php @@ -0,0 +1,27 @@ +get(\Magento\Store\Model\StoreManager::class); + +/** @var \Magento\Customer\Model\Customer $customer */ +$customer = $objectManager->create( + \Magento\Customer\Model\Customer::class, + [ + 'data' => [ + 'website_id' => $store->getDefaultStoreView()->getWebsiteId(), + 'email' => 'john.doe@magento.com', + 'store_id' => $store->getDefaultStoreView()->getId(), + 'is_active' => true, + 'firstname' => 'John', + 'lastname' => 'Doe', + ] + ] +); +$customer->save();