Skip to content

Commit 527fbbb

Browse files
committed
MAGETWO-91409: Rush theme not available on Themes Grid with clean 2.3 installation
- added functional test
1 parent e498c26 commit 527fbbb

File tree

3 files changed

+66
-0
lines changed

3 files changed

+66
-0
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
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+
9+
<pages xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/PageObject.xsd">
11+
<page name="ThemesPageIndex" url="admin/system_design_theme/" area="admin" module="Magento_Theme">
12+
<section name="AdminThemeSection"/>
13+
</page>
14+
</pages>
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
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+
9+
<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/SectionObject.xsd">
11+
<section name="AdminThemeSection">
12+
<!--All rows in a specific Column e.g. {{Section.rowsInColumn('columnName')}}-->
13+
<element name="rowsInColumn" type="text" selector="//tr/td[contains(@class, '{{column}}')]" parameterized="true"/>
14+
<!--selector for Theme Title column since it needs to be handled separately-->
15+
<element name="rowsInThemeTitleColumn" type="text" selector="//tbody/tr/td[contains(@class, 'parent_theme')]/preceding-sibling::td"/>
16+
<element name="rowsInColumn" type="text" selector="//tbody/tr/td[contains(@class, '{{column}}')]" parameterized="true"/>
17+
<!--Specific cell e.g. {{Section.gridCell('Name')}}-->
18+
<element name="gridCell" type="text" selector="//table[@id='theme_grid_table']//td[contains(text(), '{{gridCellText}}')]" parameterized="true"/>
19+
<element name="columnHeader" type="text" selector="//thead/tr/th[contains(@class, 'data-grid-th')]/span[text() = '{{label}}']" parameterized="true" timeout="30"/>
20+
</section>
21+
</sections>
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
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+
9+
<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/testSchema.xsd">
11+
<test name="ThemeTest">
12+
<annotations>
13+
<features value="Theme Test"/>
14+
<title value="Magento Rush theme should not be available in Themes grid"/>
15+
<description value="Magento Rush theme should not be available in Themes grid"/>
16+
<severity value="MAJOR"/>
17+
<testCaseId value="MAGETWO-91409"/>
18+
<group value="theme"/>
19+
</annotations>
20+
<after>
21+
<actionGroup ref="logout" stepKey="logoutOfAdmin"/>
22+
</after>
23+
<!--Login to Admin Area-->
24+
<actionGroup ref="LoginAsAdmin" stepKey="loginToAdminArea"/>
25+
<!--Navigate to Themes page-->
26+
<amOnPage url="{{ThemesPageIndex.url}}" stepKey="navigateToThemesIndexPage" />
27+
<waitForPageLoad stepKey="wait1"/>
28+
<dontSee selector="{{AdminThemeSection.gridCell('Magento Rush')}}" stepKey="dontSeeRushThemeInTitleColumn"/>
29+
<seeNumberOfElements selector="{{AdminThemeSection.rowsInColumn('theme_path')}}" userInput="2" stepKey="see2RowsOnTheGrid"/>
30+
</test>
31+
</tests>

0 commit comments

Comments
 (0)