Skip to content

Commit dc1001d

Browse files
committed
Merge remote-tracking branch 'origin/2.4-develop' into ACP2E-3131
# Conflicts: # app/code/Magento/Catalog/view/adminhtml/templates/catalog/category/widget/tree.phtml
2 parents ab2bbd6 + 3c83d94 commit dc1001d

File tree

384 files changed

+14269
-1271
lines changed

Some content is hidden

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

384 files changed

+14269
-1271
lines changed

app/code/Magento/AwsS3/Test/Unit/Driver/AwsS3Test.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -439,8 +439,8 @@ public function testSearchDirectory(): void
439439
$this->metadataProviderMock->expects(self::any())->method('getMetadata')
440440
->willReturnMap([
441441
['path', ['type' => AwsS3::TYPE_DIR]],
442-
['path/1', ['type' => AwsS3::TYPE_FILE]],
443-
['path/2', ['type' => AwsS3::TYPE_FILE]],
442+
['path/1', ['type' => AwsS3::TYPE_DIR]],
443+
['path/2', ['type' => AwsS3::TYPE_DIR]],
444444
]);
445445
$this->adapterMock->expects(self::atLeastOnce())->method('listContents')
446446
->willReturn(new \ArrayIterator($subPaths));

app/code/Magento/Backend/Test/Mftf/Section/AdminMessagesSection.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,7 @@
2323
<element name="errorMessage" type="text" selector=".message.message-error.error"/>
2424
<element name="warningMessage" type="text" selector=".message-warning"/>
2525
<element name="noticeMessage" type="text" selector=".message-notice"/>
26+
<element name="assertCacheManagementConfigurationStatus" type="button" selector="//td[@data-column='tags' and contains(text(),'CONFIG')]/following-sibling::td//span[@class='grid-severity-notice']//span"/>
27+
<element name="assertCacheManagementLayoutsStatus" type="button" selector="//td[@data-column='tags' and contains(text(),'LAYOUT_GENERAL_CACHE_TAG')]/following-sibling::td//span[@class='grid-severity-notice']//span"/>
2628
</section>
2729
</sections>

app/code/Magento/Backend/view/adminhtml/layout/default.xml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111
<meta name="viewport" content="width=1024"/>
1212
<meta name="format-detection" content="telephone=no"/>
1313
<link src="requirejs/require.js"/>
14-
<css src="extjs/resources/css/ext-all.css"/>
15-
<css src="extjs/resources/css/ytheme-magento.css"/>
1614
</head>
1715
<body>
1816
<attribute name="id" value="html-body"/>

app/code/Magento/Backend/view/adminhtml/web/js/media-uploader.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ define([
7575
byteConvert(currentFile.size);
7676

7777
// check if file is allowed to upload and resize
78-
allowedResize = $.inArray(currentFile.extension, allowedExt) !== -1;
78+
allowedResize = $.inArray(currentFile.extension?.toLowerCase(), allowedExt) !== -1;
7979

8080
if (!allowedResize) {
8181
fileUploader.aggregateError(currentFile.name,

app/code/Magento/Bundle/Test/Mftf/Test/AdminAddDefaultImageBundleProductTest.xml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,8 @@
1818
<testCaseId value="MC-115"/>
1919
<group value="Bundle"/>
2020
<group value="cloud"/>
21-
<skip>
22-
<issueId value="AC-12124">Fotorama lib isn't loaded</issueId>
23-
</skip>
21+
<!-- Excluded from PR builds due to AC-12124 -->
22+
<group value="pr_exclude"/>
2423
</annotations>
2524
<before>
2625
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>

app/code/Magento/Bundle/Test/Mftf/Test/StorefrontBundleCheckBoxOptionValidationTest.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
<group value="Bundle"/>
2020
<group value="pr_exclude"/>
2121
<group value="cloud"/>
22+
<skip>
23+
<issueId value="AC-10826"/>
24+
</skip>
2225
</annotations>
2326
<before>
2427
<createData entity="ApiProductWithDescription" stepKey="simpleProduct1" before="bundleProduct"/>

app/code/Magento/Bundle/view/adminhtml/web/js/components/bundle-dynamic-rows-grid.js

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -141,18 +141,13 @@ define([
141141
* @returns {Object} Chainable.
142142
*/
143143
initElements: function (data) {
144-
var newData = this.getNewData(data),
145-
recordIndex;
144+
var newData = this.getNewData(data);
146145

147146
this.parsePagesData(data);
148147

149148
if (newData.length) {
150149
if (this.insertData().length) {
151-
recordIndex = data.length - newData.length - 1;
152-
153-
_.each(newData, function (newRecord) {
154-
this.processingAddChild(newRecord, ++recordIndex, newRecord[this.identificationProperty]);
155-
}, this);
150+
this.parseProcessingAddChild(data, newData);
156151
}
157152
}
158153

@@ -181,6 +176,23 @@ define([
181176
this.reload();
182177
}
183178
}, this);
179+
},
180+
181+
/**
182+
* Parse and processing the add child method to update the latest records if the record index is not a number.
183+
*
184+
* @param {Array} data
185+
* @param {Array} newData
186+
*/
187+
parseProcessingAddChild: function (data, newData) {
188+
let recordIndex;
189+
190+
recordIndex = data.length - newData.length - 1;
191+
if (!isNaN(recordIndex)) {
192+
_.each(newData, function (newRecord) {
193+
this.processingAddChild(newRecord, ++recordIndex, newRecord[this.identificationProperty]);
194+
}, this);
195+
}
184196
}
185197
});
186198
});

app/code/Magento/Bundle/view/adminhtml/web/js/components/bundle-dynamic-rows.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ define([
7474
let bundleSelections = registry.get(this.name + '.' + index + '.' + this.bundleSelectionsName);
7575

7676
bundleSelections.destroyChildren();
77+
bundleSelections._elems.clear();
7778
},
7879

7980
/**
Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
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="AdminValidateLayoutConfigurationTest">
11+
<annotations>
12+
<features value="Cache"/>
13+
<stories value="Cache Management"/>
14+
<title value="Validate Configuration Cache Type"/>
15+
<description value="Validate Configuration Cache Type After Cache Management"/>
16+
<severity value="CRITICAL"/>
17+
<testCaseId value="AC-4231"/>
18+
</annotations>
19+
<before>
20+
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
21+
<createData entity="_defaultCategory" stepKey="createPreReqCategory"/>
22+
<createData entity="_defaultProduct" stepKey="createProduct">
23+
<requiredEntity createDataKey="createPreReqCategory"/>
24+
</createData>
25+
<actionGroup ref="AdminGoToCacheManagementPageActionGroup" stepKey="goToCacheManagementPage"/>
26+
<waitForText selector="{{AdminMessagesSection.assertCacheManagementConfigurationStatus}}" userInput="ENABLED" stepKey="verifyCacheTypeConfigurationIsENABLED"/>
27+
</before>
28+
<after>
29+
<!-- Delete category -->
30+
<deleteData createDataKey="createPreReqCategory" stepKey="deleteCategory"/>
31+
<!-- Delete product -->
32+
<deleteData createDataKey="createProduct" stepKey="deleteProduct"/>
33+
<!--Restore currency symbols to default-->
34+
<actionGroup ref="AdminNavigateToCurrencySymbolsPageActionGroup" stepKey="navigateToCurrencySymbolsPageToRestore"/>
35+
<checkOption selector="{{AdminCurrencySymbolsGridSection.currencyCheckBox}}" stepKey="checkConfigSettingsMessage"/>
36+
<waitForElementClickable selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="waitForSaveCurrencySymbolAgain"/>
37+
<click selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="clickSaveCurrencySymbolsToRestore"/>
38+
<!-- Flush Cache-->
39+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanCachesAfterRevokingTheChangesToDefault">
40+
<argument name="tags" value="" />
41+
</actionGroup>
42+
<!-- Log out -->
43+
<actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/>
44+
</after>
45+
<!-- Validate Storefront -->
46+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront">
47+
<argument name="page" value="$$createProduct.name$$.html"/>
48+
</actionGroup>
49+
<!--Assert Currency symbol-->
50+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="$" stepKey="waitForCurrencySymbolInStoreFront"/>
51+
<!-- Navigate To Currency Symbol-->
52+
<actionGroup ref="AdminNavigateToCurrencySymbolsPageActionGroup" stepKey="navigateToCurrencySymbolsPage"/>
53+
<!--Replace standard currency symbol by custom currency symbol-->
54+
<uncheckOption selector="{{AdminCurrencySymbolsGridSection.currencyCheckBox}}" stepKey="uncheckConfigSettingsMessage"/>
55+
<fillField selector="{{AdminCurrencySymbolsGridSection.inputCurrencySymbol}}" userInput="£" stepKey="fillDefaultLabel"/>
56+
<!--Save custom currency symbol-->
57+
<waitForElementClickable selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="waitForSaveCurrencySymbol"/>
58+
<click selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="clickSaveCurrencySymbols"/>
59+
<waitForText selector="{{AdminMessagesSection.success}}" userInput="{{AdminSaveCurrencySymbolMessageData.success}}" stepKey="seeSuccessMessage"/>
60+
<!--Navigate To Product Storefront-->
61+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront1">
62+
<argument name="page" value="$$createProduct.name$$.html"/>
63+
</actionGroup>
64+
<!--Assert Currency symbol is not changed-->
65+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="$" stepKey="verifyCurrencySymbolIsNotChangedBeforeFlushingTheChangesInStoreFront"/>
66+
<!--Navigate to Cache Management-->
67+
<actionGroup ref="AdminGoToCacheManagementPageActionGroup" stepKey="goToCacheManagementPage1"/>
68+
<!-- Flush Cache-->
69+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanCachesAfterChangesMade">
70+
<argument name="tags" value="" />
71+
</actionGroup>
72+
<!--Navigate To Product Storefront-->
73+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront2">
74+
<argument name="page" value="$$createProduct.name$$.html"/>
75+
</actionGroup>
76+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="£" stepKey="verifyCurrencySymbolIsChangedAfterFlushingTheChangesInStoreFront"/>
77+
</test>
78+
</tests>
Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
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="AdminValidateLayoutsCacheTypeTest">
11+
<annotations>
12+
<features value="Cache"/>
13+
<stories value="Cache Management"/>
14+
<title value="Validate layouts Cache Type"/>
15+
<description value="Validate layouts Cache Type After Cache Management"/>
16+
<severity value="CRITICAL"/>
17+
<testCaseId value="AC-4221"/>
18+
</annotations>
19+
<before>
20+
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
21+
<createData entity="_defaultCategory" stepKey="createPreReqCategory"/>
22+
<createData entity="_defaultProduct" stepKey="createProduct">
23+
<requiredEntity createDataKey="createPreReqCategory"/>
24+
</createData>
25+
</before>
26+
<after>
27+
<!-- Delete category -->
28+
<deleteData createDataKey="createPreReqCategory" stepKey="deleteCategory"/>
29+
<!-- Delete product -->
30+
<deleteData createDataKey="createProduct" stepKey="deleteProduct"/>
31+
<!--Restore currency symbols to default-->
32+
<actionGroup ref="AdminNavigateToCurrencySymbolsPageActionGroup" stepKey="navigateToCurrencySymbolsPageToRestore"/>
33+
<checkOption selector="{{AdminCurrencySymbolsGridSection.currencyCheckBox}}" stepKey="checkConfigSettingsMessage"/>
34+
<waitForElementClickable selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="waitForSaveCurrencySymbolAgain"/>
35+
<click selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="clickSaveCurrencySymbolsToRestore"/>
36+
<!-- Flush Cache-->
37+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanCachesAfterRevokingTheChangesToDefault">
38+
<argument name="tags" value="" />
39+
</actionGroup>
40+
<!-- Log out -->
41+
<actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/>
42+
</after>
43+
<!-- Validate Storefront -->
44+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront">
45+
<argument name="page" value="$$createProduct.name$$.html"/>
46+
</actionGroup>
47+
<!--Assert Currency symbol-->
48+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="$" stepKey="waitForCurrencySymbolInStoreFront"/>
49+
<!-- Navigate To Currency Symbol-->
50+
<actionGroup ref="AdminNavigateToCurrencySymbolsPageActionGroup" stepKey="navigateToCurrencySymbolsPage"/>
51+
<!--Replace standard currency symbol by custom currency symbol-->
52+
<uncheckOption selector="{{AdminCurrencySymbolsGridSection.currencyCheckBox}}" stepKey="uncheckConfigSettingsMessage"/>
53+
<fillField selector="{{AdminCurrencySymbolsGridSection.inputCurrencySymbol}}" userInput="£" stepKey="fillDefaultLabel"/>
54+
<!--Save custom currency symbol-->
55+
<waitForElementClickable selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="waitForSaveCurrencySymbol"/>
56+
<click selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="clickSaveCurrencySymbols"/>
57+
<waitForText selector="{{AdminMessagesSection.success}}" userInput="{{AdminSaveCurrencySymbolMessageData.success}}" stepKey="seeSuccessMessage"/>
58+
<!--Navigate To Product Storefront-->
59+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront1">
60+
<argument name="page" value="$$createProduct.name$$.html"/>
61+
</actionGroup>
62+
<!--Assert Currency symbol is not changed-->
63+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="$" stepKey="verifyCurrencySymbolIsNotChangedBeforeFlushingTheChangesInStoreFront"/>
64+
<!-- Flush Cache-->
65+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanCachesAfterChangesMade">
66+
<argument name="tags" value="" />
67+
</actionGroup>
68+
<!--Navigate To Product Storefront-->
69+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront2">
70+
<argument name="page" value="$$createProduct.name$$.html"/>
71+
</actionGroup>
72+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="£" stepKey="verifyCurrencySymbolIsChangedAfterFlushingTheChangesInStoreFront"/>
73+
</test>
74+
</tests>

0 commit comments

Comments
 (0)