File tree Expand file tree Collapse file tree 7 files changed +126
-0
lines changed Expand file tree Collapse file tree 7 files changed +126
-0
lines changed Original file line number Diff line number Diff line change 1+ <?php
2+ namespace Magento\AcceptanceTest\_default\Backend;
3+
4+ use Magento\FunctionalTestingFramework\AcceptanceTester;
5+ use \Codeception\Util\Locator;
6+ use Yandex\Allure\Adapter\Annotation\Features;
7+ use Yandex\Allure\Adapter\Annotation\Stories;
8+ use Yandex\Allure\Adapter\Annotation\Title;
9+ use Yandex\Allure\Adapter\Annotation\Description;
10+ use Yandex\Allure\Adapter\Annotation\Parameter;
11+ use Yandex\Allure\Adapter\Annotation\Severity;
12+ use Yandex\Allure\Adapter\Model\SeverityLevel;
13+ use Yandex\Allure\Adapter\Annotation\TestCaseId;
14+
15+ /**
16+ * @Description("<h3 class='y-label y-label_status_broken'>Deprecated Notice(s):</h3><ul><li>Test is deprecated</li><li>DEPRECATED ACTION GROUP in Test: DeprecatedActionGroup Deprecated action group</li><li>DEPRECATED SECTION in Test: {{DeprecatedSection.deprecatedElement}} Deprecated section</li><li>DEPRECATED ELEMENT in Test: {{DeprecatedSection.deprecatedElement}} Deprecated element</li><li>DEPRECATED DATA ENTITY in Test: {{DeprecatedData.field}} Data entity deprecated</li><li>DEPRECATED PAGE in Test: {{DeprecatedPage.url}} Deprecated page</li></ul><h3>Test files</h3>verification/TestModule/Test/DeprecatedTest.xml<br>")
17+ */
18+ class DeprecatedTestCest
19+ {
20+ /**
21+ * @Features({"TestModule"})
22+ * @Parameter(name = "AcceptanceTester", value="$I")
23+ * @param AcceptanceTester $I
24+ * @return void
25+ * @throws \Exception
26+ */
27+ public function DeprecatedTest(AcceptanceTester $I)
28+ {
29+ $I->comment("Entering Action Group [deprecatedActionGroup] DeprecatedActionGroup");
30+ $I->see("deprecated", "#element"); // stepKey: deprecatedSeeDeprecatedActionGroup
31+ $I->comment("Exiting Action Group [deprecatedActionGroup] DeprecatedActionGroup");
32+ $I->amOnPage("/test.html"); // stepKey: amOnPage
33+ }
34+ }
Original file line number Diff line number Diff line change 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 =" DeprecatedActionGroup" deprecated =" Deprecated action group" >
11+ <see stepKey =" deprecatedSee" userInput =" {{DeprecatedData.field}}" selector =" {{DeprecatedSection.deprecatedElement}}" />
12+ </actionGroup >
13+ </actionGroups >
Original file line number Diff line number Diff line change 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 =" DeprecatedData" deprecated =" Data entity deprecated" >
12+ <data key =" field" >deprecated</data >
13+ </entity >
14+ </entities >
Original file line number Diff line number Diff line change 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 =" DeprecatedPage" url =" /test.html" area =" storefront" module =" UnknownVendor_TestModule" deprecated =" Deprecated page" >
12+ <section name =" SampleSection" />
13+ </page >
14+ </pages >
Original file line number Diff line number Diff line change 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 =" DeprecatedSection" deprecated =" Deprecated section" >
12+ <element name =" deprecatedElement" type =" button" selector =" #element" deprecated =" Deprecated element" />
13+ </section >
14+ </sections >
Original file line number Diff line number Diff line change 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 =" DeprecatedTest" deprecated =" Test is deprecated" >
12+ <actionGroup ref =" DeprecatedActionGroup" stepKey =" deprecatedActionGroup" />
13+ <amOnPage url =" {{DeprecatedPage.url}}" stepKey =" amOnPage" />
14+ </test >
15+ </tests >
Original file line number Diff line number Diff line change 1+ <?php
2+ /**
3+ * Copyright © Magento, Inc. All rights reserved.
4+ * See COPYING.txt for license details.
5+ */
6+ namespace tests \verification \Tests ;
7+
8+ use tests \util \MftfTestCase ;
9+
10+ class DeprecatedTest extends MftfTestCase
11+ {
12+ /**
13+ * Tests flat generation of a deprecated test which uses deprecated entities.
14+ *
15+ * @throws \Exception
16+ * @throws \Magento\FunctionalTestingFramework\Exceptions\TestReferenceException
17+ */
18+ public function testDeprecatedTestEntitiesGeneration ()
19+ {
20+ $ this ->generateAndCompareTest ('DeprecatedTest ' );
21+ }
22+ }
You can’t perform that action at this time.
0 commit comments