File tree Expand file tree Collapse file tree 2 files changed +9
-16
lines changed
dev/tests/functional/tests/app/Magento/Catalog/Test
Block/Product/ProductList Expand file tree Collapse file tree 2 files changed +9
-16
lines changed Original file line number Diff line number Diff line change @@ -23,18 +23,11 @@ class BottomToolbar extends Block
23
23
private $ nextPageSelector = '.item.current + .item a ' ;
24
24
25
25
/**
26
- * Selector previous element
26
+ * Selector first element
27
27
*
28
28
* @var string
29
29
*/
30
- private $ previousPageSelector = '.item.pages-item-previous ' ;
31
-
32
- /**
33
- * Selector limiter block
34
- *
35
- * @var string
36
- */
37
- private $ optionBlockSelector = '.control ' ;
30
+ private $ firstPageSelector = '.item>.page ' ;
38
31
39
32
/**
40
33
* Selector option element
@@ -59,15 +52,15 @@ public function nextPage()
59
52
}
60
53
61
54
/**
62
- * Go to the previous page
55
+ * Go to the first page
63
56
*
64
57
* @return bool
65
58
*/
66
- public function previousPage ()
59
+ public function firstPage ()
67
60
{
68
- $ previousPageItem = $ this ->_rootElement ->find ($ this ->previousPageSelector );
69
- if ($ previousPageItem ->isVisible ()) {
70
- $ previousPageItem ->click ();
61
+ $ firstPageItem = $ this ->_rootElement ->find ($ this ->firstPageSelector );
62
+ if ($ firstPageItem ->isVisible ()) {
63
+ $ firstPageItem ->click ();
71
64
return true ;
72
65
}
73
66
return false ;
Original file line number Diff line number Diff line change 12
12
use Magento \Catalog \Test \Fixture \Category ;
13
13
14
14
/**
15
- * Checks pagination of storefront for correct pagination and list of products
15
+ * Checks correct pagination for list of products on storefront.
16
16
*/
17
17
class AssertPaginationCorrectOnStoreFront extends AbstractConstraint
18
18
{
@@ -56,7 +56,7 @@ public function processAssert(
56
56
$ catalogCategoryView ->getListProductBlock ()->getProductsCount (),
57
57
'Count of products on 2 page does not equivalent with declared in pagination (default value) '
58
58
);
59
- $ catalogCategoryView ->getBottomToolbar ()->previousPage ();
59
+ $ catalogCategoryView ->getBottomToolbar ()->firstPage ();
60
60
$ catalogCategoryView ->getBottomToolbar ()->setLimiterValueByIndex (1 );
61
61
\PHPUnit_Framework_Assert::assertEquals (
62
62
$ catalogCategoryView ->getBottomToolbar ()->getLimitedValueByIndex (1 ),
You can’t perform that action at this time.
0 commit comments