File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
dev/tests/integration/testsuite/Magento/Catalog/_files Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 10
10
11
11
$ attribute ->setData ('is_used_for_promo_rules ' , 1 );
12
12
13
- /** @var ProductFactory $productFactory */
13
+ /** @var \Magento\Catalog\Model\ ProductFactory $productFactory */
14
14
$ productFactory = $ objectManager ->get (Magento \Catalog \Model \ProductFactory::class);
15
15
$ product = $ productFactory ->create ();
16
16
$ product ->setTypeId (\Magento \Catalog \Model \Product \Type::TYPE_SIMPLE )
17
- ->setAttributeSetId ($ installer -> getAttributeSetId ( ' catalog_product ' , ' Default ' ))
17
+ ->setAttributeSetId ($ product -> getDefaultAttributeSetId ( ))
18
18
->setWebsiteIds ([1 ])
19
19
->setName ('Simple Product with date ' )
20
20
->setSku ('simple_with_date ' )
30
30
31
31
$ product2 = $ productFactory ->create ();
32
32
$ product2 ->setTypeId (\Magento \Catalog \Model \Product \Type::TYPE_SIMPLE )
33
- ->setAttributeSetId ($ installer -> getAttributeSetId ( ' catalog_product ' , ' Default ' ))
33
+ ->setAttributeSetId ($ product -> getDefaultAttributeSetId ( ))
34
34
->setWebsiteIds ([1 ])
35
35
->setName ('Simple Product with date -1 ' )
36
36
->setSku ('simple_with_date2 ' )
46
46
47
47
$ product3 = $ productFactory ->create ();
48
48
$ product3 ->setTypeId (\Magento \Catalog \Model \Product \Type::TYPE_SIMPLE )
49
- ->setAttributeSetId ($ installer -> getAttributeSetId ( ' catalog_product ' , ' Default ' ))
49
+ ->setAttributeSetId ($ product -> getDefaultAttributeSetId ( ))
50
50
->setWebsiteIds ([1 ])
51
51
->setName ('Simple Product with date +1 ' )
52
52
->setSku ('simple_with_date3 ' )
You can’t perform that action at this time.
0 commit comments