Skip to content

Commit ffa8549

Browse files
committed
ACP2E-111: Inconsistent product rating on category page
1 parent 4a08b92 commit ffa8549

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

app/code/Magento/Review/Test/Mftf/Section/StorefrontMyProductReviewsSection.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
<section name="StorefrontMyProductReviewsSection">
1212
<element name="reviewDescription" type="text" selector="//td[@data-th='Review']"/>
1313
<element name="reviewRating" type="text" selector="//tbody/tr[position()='{{reviewNumber}}']/td/div/div/span[contains(@style,'width: {{reviewValue}};')]" parameterized="true"/>
14-
<element name="reviewFirstRowSeeDetails" type="text" selector="#my-reviews-table > tbody > tr:nth-child(1) > td.col.actions > a" />
15-
<element name="reviewSecondRowSeeDetails" type="text" selector="#my-reviews-table > tbody > tr:nth-child(2) > td.col.actions > a" />
14+
<element name="reviewSeeDetails" type="text" selector="#my-reviews-table > tbody > tr:nth-child({{row}}) > td.col.actions > a" parameterized="true" />
1615
</section>
1716
</sections>

app/code/Magento/Review/Test/Mftf/Test/StorefrontVerifyMultipleProductRatingsOnCategoryPageTest.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@
151151
<!-- Navigate to user account and check product ratings -->
152152
<amOnPage url="review/customer/" stepKey="amOnCustomerReviewPage2"/>
153153
<!-- Click on second product review -->
154-
<click selector="{{StorefrontMyProductReviewsSection.reviewFirstRowSeeDetails}}" stepKey="clickFirstReviewRow"/>
154+
<click selector="{{StorefrontMyProductReviewsSection.reviewSeeDetails('1')}}" stepKey="clickFirstReviewRow"/>
155155
<grabAttributeFrom selector="#rating-result_$$createProduct2.id$$ span" userInput="style" stepKey="getSecondProductResultStarsUnderProductName1"/>
156156
<assertEquals stepKey="checkSecondProductResultStarsUnderProductName1">
157157
<actualResult type="string">$getSecondProductResultStarsUnderProductName1</actualResult>
@@ -160,7 +160,7 @@
160160
<!-- Navigate to user account and check product ratings -->
161161
<amOnPage url="review/customer/" stepKey="amOnCustomerReviewPage3"/>
162162
<!-- Click on first product review -->
163-
<click selector="{{StorefrontMyProductReviewsSection.reviewSecondRowSeeDetails}}" stepKey="clickSecondReviewRow"/>
163+
<click selector="{{StorefrontMyProductReviewsSection.reviewSeeDetails('2')}}" stepKey="clickSecondReviewRow"/>
164164
<grabAttributeFrom selector="#rating-result_$$createProduct1.id$$ span" userInput="style" stepKey="getFirstProductResultStarsUnderProductName2"/>
165165
<assertEquals stepKey="checkFirstProductResultStarsUnderProductName2">
166166
<actualResult type="string">$getFirstProductResultStarsUnderProductName2</actualResult>

0 commit comments

Comments
 (0)