Skip to content

Commit a87d9ec

Browse files
Merge branch '2.4-develop' into Tier4-Kings-PR-11-22-2024
2 parents 0f85af5 + 7ead0dc commit a87d9ec

File tree

84 files changed

+1799
-440
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

84 files changed

+1799
-440
lines changed

app/code/Magento/Backend/Console/Command/MaintenanceAllowIpsCommand.php

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
3-
* Copyright © Magento, Inc. All rights reserved.
4-
* See COPYING.txt for license details.
3+
* Copyright 2015 Adobe
4+
* All Rights Reserved.
55
*/
66
namespace Magento\Backend\Console\Command;
77

@@ -22,9 +22,10 @@ class MaintenanceAllowIpsCommand extends AbstractSetupCommand
2222
/**
2323
* Names of input arguments or options
2424
*/
25-
const INPUT_KEY_IP = 'ip';
26-
const INPUT_KEY_NONE = 'none';
27-
const INPUT_KEY_ADD = 'add';
25+
public const INPUT_KEY_IP = 'ip';
26+
public const INPUT_KEY_NONE = 'none';
27+
public const INPUT_KEY_ADD = 'add';
28+
public const NAME = 'maintenance:allow-ips';
2829

2930
/**
3031
* @var MaintenanceMode
@@ -76,7 +77,7 @@ protected function configure(): void
7677
'Add the IP address to existing list'
7778
),
7879
];
79-
$this->setName('maintenance:allow-ips')
80+
$this->setName(self::NAME)
8081
->setDescription('Sets maintenance mode exempt IPs')
8182
->setDefinition(array_merge($arguments, $options));
8283

app/code/Magento/Backend/Console/Command/MaintenanceDisableCommand.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
3-
* Copyright © Magento, Inc. All rights reserved.
4-
* See COPYING.txt for license details.
3+
* Copyright 2015 Adobe
4+
* All Rights Reserved.
55
*/
66
namespace Magento\Backend\Console\Command;
77

@@ -10,14 +10,16 @@
1010
*/
1111
class MaintenanceDisableCommand extends AbstractMaintenanceCommand
1212
{
13+
public const NAME = 'maintenance:disable';
14+
1315
/**
1416
* Initialization of the command
1517
*
1618
* @return void
1719
*/
1820
protected function configure()
1921
{
20-
$this->setName('maintenance:disable')->setDescription('Disables maintenance mode');
22+
$this->setName(self::NAME)->setDescription('Disables maintenance mode');
2123

2224
parent::configure();
2325
}

app/code/Magento/Backend/Console/Command/MaintenanceEnableCommand.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
3-
* Copyright © Magento, Inc. All rights reserved.
4-
* See COPYING.txt for license details.
3+
* Copyright 2015 Adobe
4+
* All Rights Reserved.
55
*/
66
namespace Magento\Backend\Console\Command;
77

@@ -10,14 +10,16 @@
1010
*/
1111
class MaintenanceEnableCommand extends AbstractMaintenanceCommand
1212
{
13+
public const NAME = 'maintenance:enable';
14+
1315
/**
1416
* Initialization of the command
1517
*
1618
* @return void
1719
*/
1820
protected function configure(): void
1921
{
20-
$this->setName('maintenance:enable')->setDescription('Enables maintenance mode');
22+
$this->setName(self::NAME)->setDescription('Enables maintenance mode');
2123

2224
parent::configure();
2325
}

app/code/Magento/Backend/Console/Command/MaintenanceStatusCommand.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
3-
* Copyright © Magento, Inc. All rights reserved.
4-
* See COPYING.txt for license details.
3+
* Copyright 2015 Adobe
4+
* All Rights Reserved.
55
*/
66
namespace Magento\Backend\Console\Command;
77

@@ -16,6 +16,8 @@
1616
*/
1717
class MaintenanceStatusCommand extends AbstractSetupCommand
1818
{
19+
public const NAME = 'maintenance:status';
20+
1921
/**
2022
* @var MaintenanceMode $maintenanceMode
2123
*/
@@ -40,7 +42,7 @@ public function __construct(MaintenanceMode $maintenanceMode)
4042
*/
4143
protected function configure(): void
4244
{
43-
$this->setName('maintenance:status')
45+
$this->setName(self::NAME)
4446
->setDescription('Displays maintenance mode status');
4547

4648
parent::configure();
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright 2024 Adobe
5+
* All Rights Reserved.
6+
*/
7+
-->
8+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
10+
<actionGroup name="AdminAddCustomOptionsActionGroup">
11+
<annotations>
12+
<description>Clicks on 'Add Option'. Adds the provided Options under the provided Custom Option Name to a Product on the Admin Product creation/edit page under the 'Customizable Options' section.</description>
13+
</annotations>
14+
<arguments>
15+
<argument name="title" type="string"/>
16+
<argument name="price" type="string"/>
17+
</arguments>
18+
<!-- Add option based on the parameter -->
19+
<click stepKey="clickAddValue" selector="{{AdminProductCustomizableOptionsSection.addValue}}"/>
20+
<fillField stepKey="fillInCustomOptionValueTitle" selector="{{AdminProductCustomizableOptionsSection.valueTitle}}" userInput="{{title}}"/>
21+
<fillField stepKey="fillInCustomOptionValuePrice" selector="{{AdminProductCustomizableOptionsSection.valuePrice}}" userInput="{{price}}"/>
22+
</actionGroup>
23+
</actionGroups>
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright 2024 Adobe
5+
* All Rights Reserved.
6+
*/
7+
-->
8+
9+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
11+
<actionGroup name="AdminAddOptionsToSizeAttributeActionGroup">
12+
<annotations>
13+
<description>Adds size option to a new Attribute on the Configurable Product creation/edit page.</description>
14+
</annotations>
15+
<arguments>
16+
<argument name="position" type="string" defaultValue="0"/>
17+
<argument name="size" type="string" defaultValue="S"/>
18+
</arguments>
19+
<!--Add option 1 to attribute-->
20+
<waitForElementVisible selector="{{AdminNewAttributePanel.optionAdminValue('position')}}" stepKey="waitForAdminTextBoxVisible"/>
21+
<fillField selector="{{AdminNewAttributePanel.optionAdminValue('position')}}" userInput="{{size}}" stepKey="fillAdminLabel"/>
22+
<waitForElementVisible selector="{{AdminNewAttributePanel.optionDefaultStoreValue('position')}}" stepKey="waitForDefaultStoreViewTextBoxVisible"/>
23+
<fillField selector="{{AdminNewAttributePanel.optionDefaultStoreValue('position')}}" userInput="{{size}}" stepKey="fillDefaultLabel"/>
24+
</actionGroup>
25+
</actionGroups>
Lines changed: 148 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,148 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright 2024 Adobe
5+
* All Rights Reserved.
6+
*/
7+
-->
8+
<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
10+
<test name="AdminSaveProductWithTwoORMorePagesOfCustomOptionsTest">
11+
<annotations>
12+
<features value="Create product"/>
13+
<stories value="Save product with 2 or more page of custom options"/>
14+
<title value="Admin should be able to Save product with 2 or more pages of custom options"/>
15+
<description value="Admin save product with 2 or more pages of custom options"/>
16+
<severity value="MAJOR"/>
17+
<testCaseId value="AC-4158"/>
18+
</annotations>
19+
<before>
20+
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
21+
</before>
22+
<after>
23+
<actionGroup ref="DeleteProductUsingProductGridActionGroup" stepKey="deleteProduct">
24+
<argument name="product" value="SimpleProduct"/>
25+
</actionGroup>
26+
<actionGroup ref="AdminLogoutActionGroup" stepKey="adminLogout"/>
27+
</after>
28+
<actionGroup ref="AdminOpenProductIndexPageActionGroup" stepKey="navigateToProductIndex"/>
29+
<actionGroup ref="GoToCreateProductPageActionGroup" stepKey="goToCreateProduct">
30+
<argument name="product" value="SimpleProduct"/>
31+
</actionGroup>
32+
<actionGroup ref="FillMainProductFormNoWeightActionGroup" stepKey="fillProductForm">
33+
<argument name="product" value="SimpleProduct"/>
34+
</actionGroup>
35+
<click selector="{{AdminProductCustomizableOptionsSection.customizableOptions}}" stepKey="openCustomizableOptions"/>
36+
<click stepKey="clickAddOptions" selector="{{AdminProductCustomizableOptionsSection.addOptionBtn}}"/>
37+
<!-- Fill in the option and select the type of drop down -->
38+
<fillField selector="{{AdminProductCustomizableOptionsSection.optionTitleInput('0')}}" userInput="{{virtualProductCustomizableOption1.title}}" stepKey="fillOptionTitleForDataSet"/>
39+
<click stepKey="clickOptionTypeParent" selector="{{AdminProductCustomizableOptionsSection.lastOptionTypeParent}}"/>
40+
<waitForPageLoad stepKey="waitForDropdownOpen"/>
41+
<click stepKey="clickOptionType" selector="{{AdminProductCustomizableOptionsSection.optionType('Drop-down')}}"/>
42+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions1">
43+
<argument name="title" value="value1"/>
44+
<argument name="price" value="10"/>
45+
</actionGroup>
46+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions2">
47+
<argument name="title" value="value2"/>
48+
<argument name="price" value="20"/>
49+
</actionGroup>
50+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions3">
51+
<argument name="title" value="value3"/>
52+
<argument name="price" value="30"/>
53+
</actionGroup>
54+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions4">
55+
<argument name="title" value="value4"/>
56+
<argument name="price" value="40"/>
57+
</actionGroup>
58+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions5">
59+
<argument name="title" value="value5"/>
60+
<argument name="price" value="50"/>
61+
</actionGroup>
62+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions6">
63+
<argument name="title" value="value6"/>
64+
<argument name="price" value="60"/>
65+
</actionGroup>
66+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions7">
67+
<argument name="title" value="value7"/>
68+
<argument name="price" value="70"/>
69+
</actionGroup>
70+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions8">
71+
<argument name="title" value="value8"/>
72+
<argument name="price" value="80"/>
73+
</actionGroup>
74+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions9">
75+
<argument name="title" value="value9"/>
76+
<argument name="price" value="90"/>
77+
</actionGroup>
78+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions10">
79+
<argument name="title" value="value10"/>
80+
<argument name="price" value="100"/>
81+
</actionGroup>
82+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions11">
83+
<argument name="title" value="value11"/>
84+
<argument name="price" value="10"/>
85+
</actionGroup>
86+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions12">
87+
<argument name="title" value="value12"/>
88+
<argument name="price" value="20"/>
89+
</actionGroup>
90+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions13">
91+
<argument name="title" value="value13"/>
92+
<argument name="price" value="30"/>
93+
</actionGroup>
94+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions14">
95+
<argument name="title" value="value14"/>
96+
<argument name="price" value="40"/>
97+
</actionGroup>
98+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions15">
99+
<argument name="title" value="value15"/>
100+
<argument name="price" value="50"/>
101+
</actionGroup>
102+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions16">
103+
<argument name="title" value="value16"/>
104+
<argument name="price" value="60"/>
105+
</actionGroup>
106+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions17">
107+
<argument name="title" value="value17"/>
108+
<argument name="price" value="70"/>
109+
</actionGroup>
110+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions18">
111+
<argument name="title" value="value18"/>
112+
<argument name="price" value="80"/>
113+
</actionGroup>
114+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions19">
115+
<argument name="title" value="value19"/>
116+
<argument name="price" value="90"/>
117+
</actionGroup>
118+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions20">
119+
<argument name="title" value="value20"/>
120+
<argument name="price" value="100"/>
121+
</actionGroup>
122+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions21">
123+
<argument name="title" value="value21"/>
124+
<argument name="price" value="10"/>
125+
</actionGroup>
126+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions22">
127+
<argument name="title" value="value22"/>
128+
<argument name="price" value="20"/>
129+
</actionGroup>
130+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions23">
131+
<argument name="title" value="value23"/>
132+
<argument name="price" value="30"/>
133+
</actionGroup>
134+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions24">
135+
<argument name="title" value="value24"/>
136+
<argument name="price" value="40"/>
137+
</actionGroup>
138+
<actionGroup ref="AdminAddCustomOptionsActionGroup" stepKey="createCustomOptions25">
139+
<argument name="title" value="value25"/>
140+
<argument name="price" value="50"/>
141+
</actionGroup>
142+
<actionGroup ref="AdminProductFormSaveActionGroup" stepKey="clickSaveButton"/>
143+
<waitForElementVisible selector="{{AdminProductMessagesSection.successMessage}}" stepKey="seeProductSavedMessage"/>
144+
<actionGroup ref="ReloadPageActionGroup" stepKey="reloadPage"/>
145+
<actionGroup ref="AdminProductFormSaveActionGroup" stepKey="clickSaveButtonAgain"/>
146+
<waitForElementVisible selector="{{AdminCategoryMessagesSection.SuccessMessage}}" stepKey="messageYouSavedTheProductIsShownAgain"/>
147+
</test>
148+
</tests>

app/code/Magento/Catalog/etc/di.xml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -554,6 +554,11 @@
554554
<type name="Magento\Catalog\Model\ResourceModel\Config">
555555
<plugin name="productListingAttributesCaching" type="Magento\Catalog\Plugin\Model\ResourceModel\Config" />
556556
</type>
557+
<type name="Magento\Catalog\Plugin\Model\ResourceModel\Config">
558+
<arguments>
559+
<argument name="cache" xsi:type="object">configured_eav_cache</argument>
560+
</arguments>
561+
</type>
557562
<preference for="Magento\Catalog\Api\ProductLinkTypeListInterface" type="Magento\Catalog\Model\Product\LinkTypeProvider" />
558563
<preference for="Magento\Catalog\Api\Data\ProductLinkAttributeInterface" type="Magento\Catalog\Model\ProductLink\Attribute" />
559564
<preference for="Magento\Catalog\Api\Data\ProductLinkTypeInterface" type="Magento\Catalog\Model\ProductLink\Type" />
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright 2024 Adobe
5+
* All Rights Reserved.
6+
*/
7+
-->
8+
9+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
10+
<actionGroup name="AdminCreateOptionsForAttributeMultiStockActionGroup" extends="GenerateConfigurationsByAttributeCodeActionGroup">
11+
<annotations>
12+
<description>Generates configurable variations based on attribute code and source.</description>
13+
</annotations>
14+
<arguments>
15+
<argument name="sourceCode" type="string" defaultValue="{{_defaultSource.source_code}}"/>
16+
<argument name="sourceQty" type="string" defaultValue="{{defaultProductQty.value}}"/>
17+
</arguments>
18+
<remove keyForRemoval="enterAttributeQuantity"/>
19+
<click selector="{{AdminConfigurableProductAssignSourcesSlideOut.assignSources}}" stepKey="clickOnAssignSources" after="clickOnApplySingleQuantityToEachSku"/>
20+
<conditionalClick selector="(//div[@class='admin__data-grid-header']//*[@data-action='grid-filter-reset'])[1]" dependentSelector="(//div[@class='admin__data-grid-header']//*[@data-action='grid-filter-reset'])[1]" visible="true" stepKey="clickClearFilters" after="clickOnAssignSources"/>
21+
<waitForPageLoad stepKey="waitForFilters" time="5" after="clickClearFilters"/>
22+
<click selector="{{AdminGridFilterControls.filters}}" stepKey="clickOnFilters" after="waitForFilters"/>
23+
<fillField userInput="{{sourceCode}}" selector="{{AdminManageSourcesGridFilterControls.code}}" stepKey="fillSourceCodeField" after="clickOnFilters"/>
24+
<click selector="{{AdminGridFilterControls.applyFilters}}" stepKey="clickOnApplyFilters" after="fillSourceCodeField"/>
25+
<click selector="{{AdminGridRow.checkboxByValue(sourceCode)}}" stepKey="selectSource" after="clickOnApplyFilters"/>
26+
<click selector="{{AdminConfigurableProductAssignSourcesSlideOut.done}}" stepKey="done" after="selectSource"/>
27+
<fillField selector="{{AdminConfigurableProductAssignSourcesSlideOut.quantityPerSourceForMultiMode}}" userInput="{{sourceQty}}" stepKey="fillQuantity" after="done"/>
28+
</actionGroup>
29+
</actionGroups>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright 2024 Adobe
5+
* All Rights Reserved.
6+
*/
7+
-->
8+
9+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
11+
<actionGroup name="AdminOpenChildVariationOfConfigurableProductActionGroup">
12+
<annotations>
13+
<description>Admin open child variation of configurable product</description>
14+
</annotations>
15+
<arguments>
16+
<argument name="variation" type="string" defaultValue="S"/>
17+
</arguments>
18+
<waitForElementClickable selector="{{AdminProductFormConfigurationsSection.variationProductLinkByName(variation)}}" stepKey="waitToClickOnFirstProductLink"/>
19+
<click selector="{{AdminProductFormConfigurationsSection.variationProductLinkByName(variation)}}" stepKey="clickOnFirstProductLink"/>
20+
</actionGroup>
21+
</actionGroups>

0 commit comments

Comments
 (0)