File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed
dev/tests/functional/tests/app/Magento/Catalog/Test
Block/Product/ProductList Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,9 @@ class TopToolbar extends Block
28
28
*/
29
29
public function getSelectSortType ()
30
30
{
31
- return $ this ->_rootElement ->find ("#sorter " )->getElements ('option[selected] ' )[0 ]->getText ();
31
+ $ selectedOption = $ this ->_rootElement ->find ($ this ->sorter )->getElements ('option[selected] ' )[0 ]->getText ();
32
+ preg_match ('/\w+\s?\w+/ ' , $ selectedOption , $ matches );
33
+ return $ matches [0 ];
32
34
}
33
35
34
36
/**
@@ -38,7 +40,8 @@ public function getSelectSortType()
38
40
*/
39
41
public function getSortType ()
40
42
{
41
- $ content = str_replace ("\r" , '' , $ this ->_rootElement ->find ($ this ->sorter )->getText ());
42
- return explode ("\n" , $ content );
43
+ $ content = $ this ->_rootElement ->find ($ this ->sorter )->getText ();
44
+ preg_match_all ('/\w+\s?\w+/ ' , $ content , $ matches );
45
+ return $ matches [0 ];
43
46
}
44
47
}
Original file line number Diff line number Diff line change 67
67
<field name =" name" xsi : type =" string" >Category%isolation%</field >
68
68
<field name =" url_key" xsi : type =" string" >category-%isolation%</field >
69
69
<field name =" parent_id" xsi : type =" array" >
70
- <item name =" dataset" xsi : type =" string" >default_subcategory </item >
70
+ <item name =" dataset" xsi : type =" string" >default </item >
71
71
</field >
72
72
<field name =" is_active" xsi : type =" string" >Yes</field >
73
73
<field name =" include_in_menu" xsi : type =" string" >Yes</field >
You can’t perform that action at this time.
0 commit comments