Skip to content

Commit a84ee26

Browse files
authored
Merge pull request #560 from magento/DeprecatedAttr
MFTF deprecation notice attributes
2 parents 53b055d + a457211 commit a84ee26

File tree

118 files changed

+851
-161
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

118 files changed

+851
-161
lines changed
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
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+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="../../../../../../../src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">
10+
<actionGroup name="DeprecatedCommentActionGroup" deprecated="This Action Group is outdated and will be deleted next release.">
11+
<comment userInput="Action group to demonstrate deprecation notices." stepKey="comment" />
12+
</actionGroup>
13+
</actionGroups>
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+
<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="../../../../../../../src/Magento/FunctionalTestingFramework/DataGenerator/etc/dataProfileSchema.xsd">
11+
<entity name="DeprecatedMessageData" deprecated="Entity is deprecated. Please use 'MessageData'.">
12+
<data key="message">Introduction to the Magento Functional Testing Framework</data>
13+
</entity>
14+
</entities>
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+
<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="../../../../../../../src/Magento/FunctionalTestingFramework/DataGenerator/etc/dataProfileSchema.xsd">
11+
<entity name="MessageData">
12+
<data key="message">Introduction to the Magento Functional Testing Framework</data>
13+
</entity>
14+
</entities>
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="../../../../../../../src/Magento/FunctionalTestingFramework/Page/etc/PageObject.xsd">
11+
<page name="DeprecatedMFTFDocPage" url="mftf/docs/introduction.html" area="storefront" module="MFTF_DevDocs" deprecated="New page was introduced. Please use 'MFTFDocPage'">
12+
<section name="contentSection" />
13+
</page>
14+
</pages>

dev/tests/functional/tests/MFTF/DevDocs/Section/ContentSection.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,6 @@
1010
xsi:noNamespaceSchemaLocation="../../../../../../../src/Magento/FunctionalTestingFramework/Page/etc/SectionObject.xsd">
1111
<section name="contentSection">
1212
<element name="pageIntro" type="text" selector=".page-intro"/>
13+
<element name="deprecatedPageIntro" type="text" selector=".page-intro-old" deprecated="New element was introduced. Please use 'contentSection.pageIntro'"/>
1314
</section>
1415
</sections>
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+
<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="../../../../../../../src/Magento/FunctionalTestingFramework/Page/etc/SectionObject.xsd">
11+
<section name="DeprecatedContentSection" deprecated="New section was introduces. Please use 'contentSection'">
12+
<element name="pageIntro" type="text" selector=".page-intro"/>
13+
</section>
14+
</sections>
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
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="../../../../../../../src/Magento/FunctionalTestingFramework/Test/etc/testSchema.xsd">
11+
<test name="DeprecatedDevDocsTest" deprecated="Test is deprecated due to more stable test was introduces. Please use 'DevDocsTest'.">
12+
<annotations>
13+
<!-- Comment in Annotations for DevDocs Test are not affecting test generation -->
14+
<features value="DevDocs available"/>
15+
<stories value="[Deprecated] MFTF DevDocs available"/>
16+
<title value="[Deprecated] Magento Functional Testing Framework Documentation is available."/>
17+
<description value="[Deprecated] Magento Functional Testing Framework Documentation is available."/>
18+
<severity value="CRITICAL"/>
19+
<group value="mftf"/>
20+
</annotations>
21+
22+
<!-- Open MFTF DevDocs Page -->
23+
<amOnPage stepKey="openMFTFDevDocPage" url="{{DeprecatedMFTFDocPage.url}}" />
24+
<see stepKey="verifyPageIntroText" selector="{{DeprecatedContentSection.pageIntro}}" userInput="{{DeprecatedMessageData.message}}" />
25+
<actionGroup ref="DeprecatedCommentActionGroup" stepKey="commentActionGroup" />
26+
</test>
27+
</tests>

dev/tests/functional/tests/MFTF/DevDocs/Test/DevDocsTest.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@
2121

2222
<!-- Open MFTF DevDocs Page -->
2323
<amOnPage stepKey="openMFTFDevDocPage" url="{{MFTFDocPage.url}}" />
24-
<see stepKey="verifyPageIntroText" selector="{{contentSection.pageIntro}}" userInput="Introduction to the Magento Functional Testing Framework" />
24+
<see stepKey="verifyPageIntroText" selector="{{contentSection.pageIntro}}" userInput="{{MessageData.message}}" />
2525
</test>
2626
</tests>

dev/tests/unit/Magento/FunctionalTestFramework/Test/Handlers/TestObjectHandlerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ public function testGetTestObject()
9292
[
9393
'features' => ['NO MODULE DETECTED'],
9494
'group' => ['test'],
95-
'description' => ['<br><br><b><font size=+0.9>Test files</font></b><br><br>']
95+
'description' => ['test_files' => '<h3>Test files</h3>', 'deprecated' => []]
9696
],
9797
[
9898
TestObjectExtractor::TEST_BEFORE_HOOK => $expectedBeforeHookObject,

dev/tests/verification/Resources/ActionGroupContainsStepKeyInArgText.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use Yandex\Allure\Adapter\Model\SeverityLevel;
1313
use Yandex\Allure\Adapter\Annotation\TestCaseId;
1414

1515
/**
16-
* @Description("<br><br><b><font size=+0.9>Test files</font></b><br><br>verification/TestModule/Test/ActionGroupTest.xml<br>")
16+
* @Description("<h3>Test files</h3>verification/TestModule/Test/ActionGroupTest.xml<br>")
1717
*/
1818
class ActionGroupContainsStepKeyInArgTextCest
1919
{

0 commit comments

Comments
 (0)