File tree Expand file tree Collapse file tree 3 files changed +41
-0
lines changed
dev/tests/integration/testsuite/Magento
CustomerImportExport/Model/Export
Customer/_files/import_export Expand file tree Collapse file tree 3 files changed +41
-0
lines changed Original file line number Diff line number Diff line change
1
+ <?php
2
+ /**
3
+ * Copyright © Magento, Inc. All rights reserved.
4
+ * See COPYING.txt for license details.
5
+ */
6
+ declare (strict_types=1 );
7
+
8
+ use Magento \TestFramework \Helper \Bootstrap ;
9
+ use Magento \Customer \Api \CustomerRepositoryInterface ;
10
+
11
+ require __DIR__ . '/customers.php ' ;
12
+ require __DIR__ . '/../../../Store/_files/website.php ' ;
13
+
14
+ $ objectManager = Bootstrap::getObjectManager ();
15
+ $ repository = $ objectManager ->create (CustomerRepositoryInterface::class);
16
+ $ customer = $ repository ->get ('customer@example.com ' );
17
+ $ customer ->setWebsiteId ($ website ->getId ());
18
+ $ repository ->save ($ customer );
Original file line number Diff line number Diff line change
1
+ <?php
2
+ /**
3
+ * Copyright © Magento, Inc. All rights reserved.
4
+ * See COPYING.txt for license details.
5
+ */
6
+ declare (strict_types=1 );
7
+
8
+ include __DIR__ . '/customers_rollback.php ' ;
9
+ include __DIR__ . '/../../../Store/_files/website_rollback.php ' ;
Original file line number Diff line number Diff line change @@ -75,6 +75,20 @@ public function testExport()
75
75
$ this ->checkExportData ($ lines , $ expectedAttributes );
76
76
}
77
77
78
+ /**
79
+ * Export with Multi Websites "Customer Main File".
80
+ *
81
+ * @magentoDataFixture Magento/Customer/_files/import_export/customers_with_websites.php
82
+ * @return void
83
+ */
84
+ public function testExportWithMultiWebsites (): void
85
+ {
86
+ $ this ->processCustomerAttribute ();
87
+ $ expectedAttributes = $ this ->getExpectedAttributes ();
88
+ $ lines = $ this ->export ($ expectedAttributes );
89
+ $ this ->checkExportData ($ lines , $ expectedAttributes );
90
+ }
91
+
78
92
/**
79
93
* Return attributes which should be exported.
80
94
*
You can’t perform that action at this time.
0 commit comments