Skip to content

Commit 6a63aac

Browse files
authored
Merge pull request #6669 from magento-tsg/2.4-develop-pr131
[Arrows] Fixes for 2.4 (pr131) (2.4-develop)
2 parents c364929 + bc4abf6 commit 6a63aac

File tree

29 files changed

+515
-110
lines changed

29 files changed

+515
-110
lines changed

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

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
<title value="Guest customer should be able to advance search Bundle product with product description"/>
1616
<description value="Guest customer should be able to advance search Bundle product with product description"/>
1717
<severity value="MAJOR"/>
18-
<testCaseId value="MC-242"/>
19-
<group value="Bundle"/>
18+
<testCaseId value="MC-25427"/>
19+
<group value="bundle"/>
2020
<group value="SearchEngineElasticsearch"/>
2121
</annotations>
2222
<before>
@@ -43,9 +43,9 @@
4343
<deleteData createDataKey="simple1" stepKey="deleteSimple1" before="deleteSimple2"/>
4444
<deleteData createDataKey="simple2" stepKey="deleteSimple2" before="delete"/>
4545
</after>
46-
<see userInput="3 items" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="see"/>
47-
<see userInput="$$product.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('1')}}" stepKey="seeProductName"/>
48-
<see userInput="$$simple1.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('2')}}" stepKey="seeSimple1ProductName"/>
49-
<see userInput="$$simple2.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('3')}}" stepKey="seeSimple2ProductName"/>
46+
<see userInput="1 item" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="see"/>
47+
<see userInput="$product.name$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('1')}}" stepKey="seeProductName"/>
48+
<comment userInput="BIC workaround" stepKey="seeSimple1ProductName"/>
49+
<comment userInput="BIC workaround" stepKey="seeSimple2ProductName"/>
5050
</test>
5151
</tests>

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

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
<title value="Guest customer should be able to advance search Bundle product with product price"/>
1616
<description value="Guest customer should be able to advance search Bundle product with product price"/>
1717
<severity value="MAJOR"/>
18-
<testCaseId value="MC-251"/>
19-
<group value="Bundle"/>
18+
<testCaseId value="MC-25435"/>
19+
<group value="bundle"/>
2020
<group value="SearchEngineElasticsearch"/>
2121
</annotations>
2222
<before>
@@ -52,9 +52,9 @@
5252
<deleteData createDataKey="simple1" stepKey="deleteSimple1" before="deleteSimple2"/>
5353
<deleteData createDataKey="simple2" stepKey="deleteSimple2" before="delete"/>
5454
</after>
55-
<see userInput="3 items" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="see"/>
56-
<see userInput="$$product.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('1')}}" stepKey="seeProductName"/>
57-
<see userInput="$$simple1.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('2')}}" stepKey="seeSimple1ProductName"/>
58-
<see userInput="$$simple2.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('3')}}" stepKey="seeSimple2ProductName"/>
55+
<see userInput="1 item" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="see"/>
56+
<see userInput="$product.name$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('1')}}" stepKey="seeProductName"/>
57+
<comment userInput="BIC workaround" stepKey="seeSimple1ProductName"/>
58+
<comment userInput="BIC workaround" stepKey="seeSimple2ProductName"/>
5959
</test>
6060
</tests>

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

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
<title value="Guest customer should be able to advance search Bundle product with product short description"/>
1616
<description value="Guest customer should be able to advance search Bundle product with product short description"/>
1717
<severity value="MAJOR"/>
18-
<testCaseId value="MC-250"/>
19-
<group value="Bundle"/>
18+
<testCaseId value="MC-25434"/>
19+
<group value="bundle"/>
2020
<group value="SearchEngineElasticsearch"/>
2121
</annotations>
2222
<before>
@@ -43,9 +43,9 @@
4343
<deleteData createDataKey="simple1" stepKey="deleteSimple1" before="deleteSimple2"/>
4444
<deleteData createDataKey="simple2" stepKey="deleteSimple2" before="delete"/>
4545
</after>
46-
<see userInput="3 items" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="see"/>
47-
<see userInput="$$product.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('1')}}" stepKey="seeProductName"/>
48-
<see userInput="$$simple1.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('2')}}" stepKey="seeSimple1ProductName"/>
49-
<see userInput="$$simple2.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('3')}}" stepKey="seeSimple2ProductName"/>
46+
<see userInput="1 item" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="see"/>
47+
<see userInput="$product.name$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('1')}}" stepKey="seeProductName"/>
48+
<comment userInput="BIC workaround" stepKey="seeSimple1ProductName"/>
49+
<comment userInput="BIC workaround" stepKey="seeSimple2ProductName"/>
5050
</test>
5151
</tests>

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

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
<title value="Guest customer should be able to advance search Bundle product with product name"/>
1616
<description value="Guest customer should be able to advance search Bundle product with product name"/>
1717
<severity value="MAJOR"/>
18-
<testCaseId value="MC-139"/>
19-
<group value="Bundle"/>
18+
<testCaseId value="MC-25342"/>
19+
<group value="bundle"/>
2020
<group value="SearchEngineElasticsearch"/>
2121
</annotations>
2222
<before>
@@ -43,9 +43,9 @@
4343
<deleteData createDataKey="simple1" stepKey="deleteSimple1" before="deleteSimple2"/>
4444
<deleteData createDataKey="simple2" stepKey="deleteSimple2" before="delete"/>
4545
</after>
46-
<see userInput="3 items" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="see"/>
47-
<see userInput="$$product.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('1')}}" stepKey="seeProductName"/>
48-
<see userInput="$$simple1.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('2')}}" stepKey="seeSimple1ProductName"/>
49-
<see userInput="$$simple2.name$$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('3')}}" stepKey="seeSimple2ProductName"/>
46+
<see userInput="1 item" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="see"/>
47+
<see userInput="$product.name$" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.nthProductName('1')}}" stepKey="seeProductName"/>
48+
<comment userInput="BIC workaround" stepKey="seeSimple1ProductName"/>
49+
<comment userInput="BIC workaround" stepKey="seeSimple2ProductName"/>
5050
</test>
5151
</tests>

app/code/Magento/Catalog/Test/Mftf/Section/StorefrontProductCompareMainSection.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
<element name="ProductPriceByName" type="text" selector="//*[@id='product-comparison']//td[.//strong[@class='product-item-name']/a[contains(text(), '{{var1}}')]]//span[@class='price']" parameterized="true"/>
1515
<element name="ProductImageByName" type="text" selector="//*[@id='product-comparison']//td[.//strong[@class='product-item-name']/a[contains(text(), '{{var1}}')]]//img[@class='product-image-photo']" parameterized="true"/>
1616
<element name="ProductAttributeByCodeAndProductName" type="text" selector="//*[@id='product-comparison']//tr[.//th[./span[contains(text(), '{{var1}}')]]]//td[count(//*[@id='product-comparison']//tr//td[.//strong[@class='product-item-name']/a[contains(text(), '{{var2}}')]]/preceding-sibling::td)+1]/div" parameterized="true"/>
17+
<element name="ProductAddToCartButton" type="button" selector=".product-item-photo[title='{{productName}}'] ~ .product-item-actions button[type='submit']" parameterized="true" timeout="30"/>
1718
<element name="removeFirstItem" type="button" selector="table.table-comparison a.delete"/>
1819
</section>
1920
</sections>

app/code/Magento/Catalog/Test/Mftf/Test/AdminMassUpdateProductAttributesStoreViewScopeTest/AdminMassUpdateProductAttributesStoreViewScopeTest.xml

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
<title value="Admin should be able to mass update product attributes in store view scope"/>
1515
<description value="Admin should be able to mass update product attributes in store view scope"/>
1616
<severity value="AVERAGE"/>
17-
<testCaseId value="MC-128"/>
18-
<group value="Catalog"/>
17+
<testCaseId value="MC-25333"/>
18+
<group value="catalog"/>
1919
<group value="Product Attributes"/>
2020
<group value="SearchEngineElasticsearch"/>
2121
</annotations>
@@ -51,35 +51,43 @@
5151
<actionGroup ref="AdminSwitchStoreViewActionGroup" stepKey="AdminSwitchStoreViewActionGroup"/>
5252
<!-- Update attribute -->
5353
<click selector="{{AdminEditProductAttributesSection.ChangeAttributeDescriptionToggle}}" stepKey="toggleToChangeDescription"/>
54-
<fillField selector="{{AdminEditProductAttributesSection.AttributeDescription}}" userInput="Updated $$createProductOne.custom_attributes[description]$$" stepKey="fillAttributeDescriptionField"/>
54+
<fillField selector="{{AdminEditProductAttributesSection.AttributeDescription}}" userInput="Updated $createProductOne.custom_attributes[description]$" stepKey="fillAttributeDescriptionField"/>
5555
<click selector="{{AdminEditProductAttributesSection.Save}}" stepKey="save"/>
5656
<see selector="{{AdminProductMessagesSection.successMessage}}" userInput="Message is added to queue" stepKey="seeAttributeUpateSuccessMsg"/>
5757

58+
<!-- Start message queue for product attribute consumer -->
59+
<actionGroup ref="CliConsumerStartActionGroup" stepKey="startMessageQueue">
60+
<argument name="consumerName" value="{{AdminProductAttributeUpdateMessageConsumerData.consumerName}}"/>
61+
<argument name="maxMessages" value="{{AdminProductAttributeUpdateMessageConsumerData.messageLimit}}"/>
62+
</actionGroup>
5863

5964
<!-- Assert on storefront default view with partial word of product name -->
6065
<actionGroup ref="GoToStoreViewAdvancedCatalogSearchActionGroup" stepKey="GoToStoreViewAdvancedCatalogSearchActionGroupDefault"/>
6166
<actionGroup ref="StorefrontAdvancedCatalogSearchByProductNameAndDescriptionActionGroup" stepKey="searchByNameDefault">
62-
<argument name="name" value="$$createProductOne.name$$"/>
63-
<argument name="description" value="$$createProductOne.custom_attributes[description]$$"/>
67+
<argument name="name" value="$createProductOne.name$"/>
68+
<argument name="description" value="$createProductOne.custom_attributes[description]$"/>
6469
</actionGroup>
6570
<actionGroup ref="StorefrontCheckAdvancedSearchResultActionGroup" stepKey="StorefrontCheckAdvancedSearchResultDefault"/>
66-
<see userInput="2 item" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="seeInDefault"/>
71+
<see userInput="1 item" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="seeInDefault"/>
6772

6873
<!-- Assert on storefront custom view with partial word of product name -->
6974
<actionGroup ref="GoToStoreViewAdvancedCatalogSearchActionGroup" stepKey="GoToStoreViewAdvancedCatalogSearchActionGroupCustom"/>
7075
<actionGroup ref="StorefrontSwitchStoreViewActionGroup" stepKey="StorefrontSwitchStoreViewActionGroup"/>
7176
<actionGroup ref="StorefrontAdvancedCatalogSearchByProductNameAndDescriptionActionGroup" stepKey="searchByNameCustom">
72-
<argument name="name" value="$$createProductOne.name$$"/>
73-
<argument name="description" value="Updated $$createProductOne.custom_attributes[description]$$"/>
77+
<argument name="name" value="$createProductTwo.name$"/>
78+
<argument name="description" value="Updated $createProductOne.custom_attributes[description]$"/>
7479
</actionGroup>
7580
<actionGroup ref="StorefrontCheckAdvancedSearchResultActionGroup" stepKey="StorefrontCheckAdvancedSearchResultCustom"/>
76-
<see userInput="2 item" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="seeInCustom"/>
81+
<see userInput="1 item" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="seeInCustom"/>
7782

7883
<!-- Assert Storefront default view with exact product name -->
7984
<actionGroup ref="GoToStoreViewAdvancedCatalogSearchActionGroup" stepKey="GoToStoreViewAdvancedCatalogSearchActionGroupDefault1"/>
85+
<actionGroup ref="StorefrontSwitchStoreViewActionGroup" stepKey="switchToDefaultStoreView">
86+
<argument name="storeView" value="_defaultStore"/>
87+
</actionGroup>
8088
<actionGroup ref="StorefrontAdvancedCatalogSearchByProductNameAndDescriptionActionGroup" stepKey="searchByNameDefault1">
81-
<argument name="name" value="$$createProductThree.name$$"/>
82-
<argument name="description" value="$$createProductThree.custom_attributes[description]$$"/>
89+
<argument name="name" value="$createProductThree.name$"/>
90+
<argument name="description" value="$createProductThree.custom_attributes[description]$"/>
8391
</actionGroup>
8492
<actionGroup ref="StorefrontCheckAdvancedSearchResultActionGroup" stepKey="StorefrontCheckAdvancedSearchResultDefault1"/>
8593
<see userInput="1 item" selector="{{StorefrontCatalogSearchAdvancedResultMainSection.itemFound}}" stepKey="seeInDefault1"/>

app/code/Magento/Catalog/view/frontend/templates/product/compare/list.phtml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
action="<?= $block->escapeUrl($this->helper(Magento\Catalog\Helper\Product\Compare::class)->getAddToCartUrl($item)) ?>"
7474
method="post">
7575
<?= $block->getBlockHtml('formkey') ?>
76-
<button type="submit" class="action tocart primary">
76+
<button type="submit" class="action tocart primary" disabled>
7777
<span><?= $block->escapeHtml(__('Add to Cart')) ?></span>
7878
</button>
7979
</form>
@@ -144,15 +144,13 @@
144144
</tbody>
145145
</table>
146146
</div>
147-
<?php if (!$block->isRedirectToCartEnabled()) :?>
148-
<script type="text/x-magento-init">
149-
{
150-
"[data-role=tocart-form]": {
151-
"catalogAddToCart": {}
152-
}
147+
<script type="text/x-magento-init">
148+
{
149+
"[data-role=tocart-form]": {
150+
"catalogAddToCart": {}
153151
}
154-
</script>
155-
<?php endif; ?>
152+
}
153+
</script>
156154
<?php else :?>
157155
<div class="message info empty"><div><?= $block->escapeHtml(__('You have no items to compare.')) ?></div></div>
158156
<?php endif; ?>

app/code/Magento/Catalog/view/frontend/templates/product/list.phtml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -154,15 +154,13 @@ $_helper = $block->getData('outputHelper');
154154
</ol>
155155
</div>
156156
<?= $block->getToolbarHtml() ?>
157-
<?php if (!$block->isRedirectToCartEnabled()): ?>
158-
<script type="text/x-magento-init">
159-
{
160-
"[data-role=tocart-form], .form.map.checkout": {
161-
"catalogAddToCart": {
162-
"product_sku": "<?= $escaper->escapeJs($_product->getSku()) ?>"
163-
}
157+
<script type="text/x-magento-init">
158+
{
159+
"[data-role=tocart-form], .form.map.checkout": {
160+
"catalogAddToCart": {
161+
"product_sku": "<?= $escaper->escapeJs($_product->getSku()) ?>"
164162
}
165163
}
166-
</script>
167-
<?php endif; ?>
164+
}
165+
</script>
168166
<?php endif; ?>

app/code/Magento/Catalog/view/frontend/templates/product/view/options/type/file.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
id="<?= /* @noEscape */ $_fileName ?>"
5252
class="product-custom-option<?= $_option->getIsRequire() ? ' required' : '' ?>"
5353
<?= $_fileExists ? 'disabled="disabled"' : '' ?> />
54-
<input type="hidden" name="<?= /* @noEscape */ $_fieldNameAction ?>"
54+
<input type="hidden" class="product-custom-option" name="<?= /* @noEscape */ $_fieldNameAction ?>"
5555
value="<?= /* @noEscape */ $_fieldValueAction ?>" />
5656
<?php if ($_option->getFileExtension()):?>
5757
<p class="note">

app/code/Magento/CatalogSearch/Model/Search/RequestGenerator.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ private function generateAdvancedSearchRequest()
186186
[
187187
'field' => $attribute->getAttributeCode(),
188188
'boost' => $attribute->getSearchWeight() ?: 1,
189+
'matchCondition' => 'match_phrase_prefix',
189190
],
190191
],
191192
];

0 commit comments

Comments
 (0)