Skip to content

Commit

Permalink
Merge pull request #38 from magento-lynx/MC-42290
Browse files Browse the repository at this point in the history
MC-42290: Check bind changes are covered by test
  • Loading branch information
eliseacornejo authored May 19, 2021
2 parents 98b3ee6 + af4a2d3 commit d8b9fff
Show file tree
Hide file tree
Showing 6 changed files with 95 additions and 148 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
<actionGroup name="AdminClickViewThemeActionGroup">
<annotations>
<description>Clicks on 'View' action of one theme on the themes grid.</description>
</annotations>
<click selector="{{AdminThemeSection.viewAction}}" stepKey="clickViewTheme"/>
</actionGroup>
</actionGroups>
16 changes: 16 additions & 0 deletions app/code/Magento/Theme/Test/Mftf/Data/ThemeData.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd">
<entity name="MagentoBlankTheme">
<data key="pageTitle">Theme: Magento Blank</data>
<data key="themePath">Magento/blank</data>
<data key="themeTitle">Magento Blank</data>
</entity>
</entities>
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,6 @@
<element name="gridCell" type="text" selector="//table//div[contains(text(), '{{gridCellText}}')]" parameterized="true"/>
<element name="gridCellUpdated" type="text" selector="//tbody//tr//div[contains(text(), '{{gridCellText}}')]" parameterized="true"/>
<element name="columnHeader" type="text" selector="//thead/tr/th[contains(@class, 'data-grid-th')]/span[text() = '{{label}}']" parameterized="true" timeout="30"/>
<element name="viewAction" type="button" selector="tr.data-row > td.data-grid-actions-cell > a.action-menu-item"/>
</section>
</sections>
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="AdminThemeSettingsSection">
<element name="themePath" type="text" selector=".field-theme_path"/>
<element name="themeTitle" type="text" selector=".field-theme_title"/>
<element name="themePreviewImage" type="text" selector="//div[contains(@class, 'field-preview_image')]//label//span[contains(text(), 'Theme Preview Image')]"/>
</section>
</sections>
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
<test name="AdminContentThemesEditTest">
<annotations>
<features value="Theme"/>
<stories value="Menu Navigation"/>
<title value="Admin content themes edit test"/>
<description value="Admin should be able to view a theme"/>
<severity value="CRITICAL"/>
<group value="menu"/>
<group value="mtf_migrated"/>
</annotations>
<before>
<actionGroup ref="AdminLoginActionGroup" stepKey="LoginAsAdmin"/>
</before>
<after>
<actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/>
</after>
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToContentThemesPage">
<argument name="menuUiId" value="{{AdminMenuContent.dataUiId}}"/>
<argument name="submenuUiId" value="{{AdminMenuContentDesignThemes.dataUiId}}"/>
</actionGroup>
<actionGroup ref="AdminAssertPageTitleActionGroup" stepKey="seePageTitle">
<argument name="title" value="{{AdminMenuContentDesignThemes.pageTitle}}"/>
</actionGroup>

<actionGroup ref="AdminClickViewThemeActionGroup" stepKey="editTheme"/>

<actionGroup ref="AdminAssertPageTitleActionGroup" stepKey="seeEditPageTitle">
<argument name="title" value="{{MagentoBlankTheme.pageTitle}}"/>
</actionGroup>

<see selector="{{AdminThemeSettingsSection.themePath}}" userInput="{{MagentoBlankTheme.themePath}}" stepKey="assertThemePath"/>
<see selector="{{AdminThemeSettingsSection.themeTitle}}" userInput="{{MagentoBlankTheme.themeTitle}}" stepKey="assertThemeTitle"/>
<seeElementInDOM selector="{{AdminThemeSettingsSection.themePreviewImage}}" stepKey="seeThemePreviewImage"/>
</test>
</tests>
148 changes: 0 additions & 148 deletions lib/web/mage/list.js

This file was deleted.

0 comments on commit d8b9fff

Please sign in to comment.