Skip to content

MQE-1472: Action Group context in Tests and Allure #319

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Apr 9, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ class ActionGroupContainsStepKeyInArgTextCest
*/
public function _before(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupContainsStepKeyInArgValue (actionGroup)");
$I->see("arg1", ".selector");
$I->comment("Exiting Action Group actionGroupContainsStepKeyInArgValue (actionGroup)");
}

/**
Expand All @@ -36,6 +38,8 @@ class ActionGroupContainsStepKeyInArgTextCest
*/
public function ActionGroupContainsStepKeyInArgText(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupContainsStepKeyInArgValue (actionGroup)");
$I->see("arg1", ".selector");
$I->comment("Exiting Action Group actionGroupContainsStepKeyInArgValue (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,13 @@ class ActionGroupMergedViaInsertAfterCest
*/
public function ActionGroupMergedViaInsertAfter(AcceptanceTester $I)
{
$I->comment("Entering Action Group FunctionalActionGroupForMassMergeAfter (keyone)");
$I->fillField("#foo", "foo");
$I->fillField("#bar", "bar");
$I->click("#foo2");
$I->click("#bar2");
$I->click("#baz2");
$I->fillField("#baz", "baz");
$I->comment("Exiting Action Group FunctionalActionGroupForMassMergeAfter (keyone)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,13 @@ class ActionGroupMergedViaInsertBeforeCest
*/
public function ActionGroupMergedViaInsertBefore(AcceptanceTester $I)
{
$I->comment("Entering Action Group FunctionalActionGroupForMassMergeBefore (keyone)");
$I->fillField("#foo", "foo");
$I->click("#foo2");
$I->click("#bar2");
$I->click("#baz2");
$I->fillField("#bar", "bar");
$I->fillField("#baz", "baz");
$I->comment("Exiting Action Group FunctionalActionGroupForMassMergeBefore (keyone)");
}
}
2 changes: 2 additions & 0 deletions dev/tests/verification/Resources/ActionGroupSkipReadiness.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,10 @@ class ActionGroupSkipReadinessCest
*/
public function ActionGroupSkipReadiness(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithSkipReadinessActions (skipReadinessActionGroup)");
$I->skipReadinessCheck(true);
$I->comment("ActionGroupSkipReadiness");
$I->skipReadinessCheck(false);
$I->comment("Exiting Action Group actionGroupWithSkipReadinessActions (skipReadinessActionGroup)");
}
}
2 changes: 2 additions & 0 deletions dev/tests/verification/Resources/ActionGroupToExtend.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ class ActionGroupToExtendCest
*/
public function ActionGroupToExtend(AcceptanceTester $I)
{
$I->comment("Entering Action Group ActionGroupToExtend (actionGroup)");
$grabProductsActionGroup = $I->grabMultiple("selector");
$I->assertCount(99, $grabProductsActionGroup);
$I->comment("Exiting Action Group ActionGroupToExtend (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ class ActionGroupUsingCreateDataCest
*/
public function _before(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithCreateData (Key1)");
$I->amGoingTo("create entity that has the stepKey: createCategoryKey1");
PersistedObjectHandler::getInstance()->createEntity(
"createCategoryKey1",
Expand All @@ -40,6 +41,7 @@ class ActionGroupUsingCreateDataCest
["createCategoryKey1"],
null
);
$I->comment("Exiting Action Group actionGroupWithCreateData (Key1)");
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ class ActionGroupUsingNestedArgumentCest
*/
public function ActionGroupUsingNestedArgument(AcceptanceTester $I)
{
$I->comment("Entering Action Group ActionGroupToExtend (actionGroup)");
$grabProductsActionGroup = $I->grabMultiple("selector");
$I->assertCount(99, $grabProductsActionGroup);
$I->comment("Exiting Action Group ActionGroupToExtend (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,10 @@ class ActionGroupWithDataOverrideTestCest
[],
null
);
$I->comment("Entering Action Group FunctionalActionGroup (beforeGroup)");
$I->fillField("#foo", "myData1");
$I->fillField("#bar", "myData2");
$I->comment("Exiting Action Group FunctionalActionGroup (beforeGroup)");
}

/**
Expand All @@ -43,8 +45,10 @@ class ActionGroupWithDataOverrideTestCest
*/
public function _after(AcceptanceTester $I)
{
$I->comment("Entering Action Group FunctionalActionGroup (afterGroup)");
$I->fillField("#foo", "myData1");
$I->fillField("#bar", "myData2");
$I->comment("Exiting Action Group FunctionalActionGroup (afterGroup)");
}

/**
Expand All @@ -68,11 +72,13 @@ class ActionGroupWithDataOverrideTestCest
public function ActionGroupWithDataOverrideTest(AcceptanceTester $I)
{
$I->amOnPage("/someUrl");
$I->comment("Entering Action Group FunctionalActionGroupWithData (actionGroupWithDataOverride1)");
$I->amOnPage("/John/Doe.html");
$I->fillField("#foo", "John");
$I->fillField("#bar", "Doe");
$I->searchAndMultiSelectOption("#foo", ["John", "Doe"]);
$I->see("#element .John");
$I->comment("Exiting Action Group FunctionalActionGroupWithData (actionGroupWithDataOverride1)");
$I->click("loginButton");
}
}
6 changes: 6 additions & 0 deletions dev/tests/verification/Resources/ActionGroupWithDataTest.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,10 @@ class ActionGroupWithDataTestCest
[],
null
);
$I->comment("Entering Action Group FunctionalActionGroup (beforeGroup)");
$I->fillField("#foo", "myData1");
$I->fillField("#bar", "myData2");
$I->comment("Exiting Action Group FunctionalActionGroup (beforeGroup)");
}

/**
Expand All @@ -43,8 +45,10 @@ class ActionGroupWithDataTestCest
*/
public function _after(AcceptanceTester $I)
{
$I->comment("Entering Action Group FunctionalActionGroup (afterGroup)");
$I->fillField("#foo", "myData1");
$I->fillField("#bar", "myData2");
$I->comment("Exiting Action Group FunctionalActionGroup (afterGroup)");
}

/**
Expand All @@ -68,11 +72,13 @@ class ActionGroupWithDataTestCest
public function ActionGroupWithDataTest(AcceptanceTester $I)
{
$I->amOnPage("/someUrl");
$I->comment("Entering Action Group FunctionalActionGroupWithData (actionGroupWithData1)");
$I->amOnPage("/Jane/Dane.html");
$I->fillField("#foo", "Jane");
$I->fillField("#bar", "Dane");
$I->searchAndMultiSelectOption("#foo", ["Jane", "Dane"]);
$I->see("#element .Jane");
$I->comment("Exiting Action Group FunctionalActionGroupWithData (actionGroupWithData1)");
$I->click("loginButton");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ class ActionGroupWithDefaultArgumentAndStringSelectorParamCest
*/
public function ActionGroupWithDefaultArgumentAndStringSelectorParam(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithDefaultArgumentAndStringSelectorParam (actionGroup)");
$I->see("John", "#element .test1");
$I->comment("Exiting Action Group actionGroupWithDefaultArgumentAndStringSelectorParam (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ class ActionGroupWithMultipleParameterSelectorsFromDefaultArgumentCest
*/
public function ActionGroupWithMultipleParameterSelectorsFromDefaultArgument(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithMultipleParameterSelectorsFromArgument (actionGroup)");
$I->see("Doe", "#John-Doe .test");
$I->comment("Exiting Action Group actionGroupWithMultipleParameterSelectorsFromArgument (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ class ActionGroupWithNoArgumentsCest
*/
public function ActionGroupWithNoArguments(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithoutArguments (actionGroup)");
$I->wait(1);
$I->comment("Exiting Action Group actionGroupWithoutArguments (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,10 @@ class ActionGroupWithNoDefaultTestCest
[],
null
);
$I->comment("Entering Action Group FunctionalActionGroup (beforeGroup)");
$I->fillField("#foo", "myData1");
$I->fillField("#bar", "myData2");
$I->comment("Exiting Action Group FunctionalActionGroup (beforeGroup)");
}

/**
Expand All @@ -43,8 +45,10 @@ class ActionGroupWithNoDefaultTestCest
*/
public function _after(AcceptanceTester $I)
{
$I->comment("Entering Action Group FunctionalActionGroup (afterGroup)");
$I->fillField("#foo", "myData1");
$I->fillField("#bar", "myData2");
$I->comment("Exiting Action Group FunctionalActionGroup (afterGroup)");
}

/**
Expand All @@ -68,9 +72,11 @@ class ActionGroupWithNoDefaultTestCest
public function ActionGroupWithNoDefaultTest(AcceptanceTester $I)
{
$I->amOnPage("/someUrl");
$I->comment("Entering Action Group FunctionalActionGroupNoDefault (actionGroupWithDataOverride1)");
$I->fillField("#foo", "Jane");
$I->fillField("#bar", "Dane");
$I->see("#Jane .Dane");
$I->comment("Exiting Action Group FunctionalActionGroupNoDefault (actionGroupWithDataOverride1)");
$I->click("loginButton");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ class ActionGroupWithParameterizedElementWithHyphenCest
*/
public function ActionGroupWithParameterizedElementWithHyphen(AcceptanceTester $I)
{
$I->comment("Entering Action Group SectionArgumentWithParameterizedSelector (actionGroup)");
$keyoneActionGroup = $I->executeJS("#element .full-width");
$I->comment("Exiting Action Group SectionArgumentWithParameterizedSelector (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ class ActionGroupWithPassedArgumentAndStringSelectorParamCest
*/
public function ActionGroupWithPassedArgumentAndStringSelectorParam(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithDefaultArgumentAndStringSelectorParam (actionGroup)");
$I->see("John" . msq("UniquePerson"), "#element .test1");
$I->comment("Exiting Action Group actionGroupWithDefaultArgumentAndStringSelectorParam (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,10 @@ class ActionGroupWithPersistedDataCest
[],
null
);
$I->comment("Entering Action Group FunctionalActionGroup (beforeGroup)");
$I->fillField("#foo", "myData1");
$I->fillField("#bar", "myData2");
$I->comment("Exiting Action Group FunctionalActionGroup (beforeGroup)");
}

/**
Expand All @@ -43,8 +45,10 @@ class ActionGroupWithPersistedDataCest
*/
public function _after(AcceptanceTester $I)
{
$I->comment("Entering Action Group FunctionalActionGroup (afterGroup)");
$I->fillField("#foo", "myData1");
$I->fillField("#bar", "myData2");
$I->comment("Exiting Action Group FunctionalActionGroup (afterGroup)");
}

/**
Expand Down Expand Up @@ -75,10 +79,12 @@ class ActionGroupWithPersistedDataCest
[],
null
);
$I->comment("Entering Action Group FunctionalActionGroupWithData (actionGroupWithPersistedData1)");
$I->amOnPage("/" . PersistedObjectHandler::getInstance()->retrieveEntityField('createPerson', 'firstname', 'test') . "/" . PersistedObjectHandler::getInstance()->retrieveEntityField('createPerson', 'lastname', 'test') . ".html");
$I->fillField("#foo", PersistedObjectHandler::getInstance()->retrieveEntityField('createPerson', 'firstname', 'test'));
$I->fillField("#bar", PersistedObjectHandler::getInstance()->retrieveEntityField('createPerson', 'lastname', 'test'));
$I->searchAndMultiSelectOption("#foo", [PersistedObjectHandler::getInstance()->retrieveEntityField('createPerson', 'firstname', 'test'), PersistedObjectHandler::getInstance()->retrieveEntityField('createPerson', 'lastname', 'test')]);
$I->see("#element ." . PersistedObjectHandler::getInstance()->retrieveEntityField('createPerson', 'firstname', 'test'));
$I->comment("Exiting Action Group FunctionalActionGroupWithData (actionGroupWithPersistedData1)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ class ActionGroupWithSectionAndDataAsArgumentsCest
*/
public function ActionGroupWithSectionAndDataAsArguments(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithSectionAndData (actionGroup)");
$I->waitForElementVisible("#element .John", 10);
$I->comment("Exiting Action Group actionGroupWithSectionAndData (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ class ActionGroupWithSimpleDataUsageFromDefaultArgumentCest
*/
public function ActionGroupWithSimpleDataUsageFromDefaultArgument(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithStringUsage (actionGroup)");
$I->see("stringLiteral", "#element .stringLiteral");
$I->comment("Exiting Action Group actionGroupWithStringUsage (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,35 @@ class ActionGroupWithSimpleDataUsageFromPassedArgumentCest
*/
public function ActionGroupWithSimpleDataUsageFromPassedArgument(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithStringUsage (actionGroup1)");
$I->see("overrideString", "#element .overrideString");
$I->comment("Exiting Action Group actionGroupWithStringUsage (actionGroup1)");
$I->comment("Entering Action Group actionGroupWithStringUsage (actionGroup11)");
$I->see("1", "#element .1");
$I->comment("Exiting Action Group actionGroupWithStringUsage (actionGroup11)");
$I->comment("Entering Action Group actionGroupWithStringUsage (actionGroup12)");
$I->see("1.5", "#element .1.5");
$I->comment("Exiting Action Group actionGroupWithStringUsage (actionGroup12)");
$I->comment("Entering Action Group actionGroupWithStringUsage (actionGroup13)");
$I->see("true", "#element .true");
$I->comment("Exiting Action Group actionGroupWithStringUsage (actionGroup13)");
$I->comment("Entering Action Group actionGroupWithStringUsage (actionGroup2)");
$I->see("simpleData.firstname", "#element .simpleData.firstname");
$I->comment("Exiting Action Group actionGroupWithStringUsage (actionGroup2)");
$I->comment("Entering Action Group actionGroupWithStringUsage (actionGroup3)");
$I->see(PersistedObjectHandler::getInstance()->retrieveEntityField('persisted', 'data', 'test'), "#element ." . PersistedObjectHandler::getInstance()->retrieveEntityField('persisted', 'data', 'test'));
$I->comment("Exiting Action Group actionGroupWithStringUsage (actionGroup3)");
$I->comment("Entering Action Group actionGroupWithEntityUsage (actionGroup4)");
$I->see("John", "#element .John");
$I->comment("Exiting Action Group actionGroupWithEntityUsage (actionGroup4)");
$I->comment("Entering Action Group actionGroupWithEntityUsage (actionGroup5)");
$I->see(PersistedObjectHandler::getInstance()->retrieveEntityField('simpleData', 'firstname', 'test'), "#element ." . PersistedObjectHandler::getInstance()->retrieveEntityField('simpleData', 'firstname', 'test'));
$I->comment("Exiting Action Group actionGroupWithEntityUsage (actionGroup5)");
$I->comment("Entering Action Group actionGroupWithEntityUsage (actionGroup6)");
$I->see(PersistedObjectHandler::getInstance()->retrieveEntityField('simpleData', 'firstname[0]', 'test'), "#element ." . PersistedObjectHandler::getInstance()->retrieveEntityField('simpleData', 'firstname[0]', 'test'));
$I->comment("Exiting Action Group actionGroupWithEntityUsage (actionGroup6)");
$I->comment("Entering Action Group actionGroupWithEntityUsage (actionGroup7)");
$I->see(PersistedObjectHandler::getInstance()->retrieveEntityField('simpleData', 'firstname[data_index]', 'test'), "#element ." . PersistedObjectHandler::getInstance()->retrieveEntityField('simpleData', 'firstname[data_index]', 'test'));
$I->comment("Exiting Action Group actionGroupWithEntityUsage (actionGroup7)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ class ActionGroupWithSingleParameterSelectorFromDefaultArgumentCest
*/
public function ActionGroupWithSingleParameterSelectorFromDefaultArgument(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithSingleParameterSelectorFromArgument (actionGroup)");
$I->see("Doe", "#element .John");
$I->comment("Exiting Action Group actionGroupWithSingleParameterSelectorFromArgument (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ class ActionGroupWithSingleParameterSelectorFromPassedArgumentCest
*/
public function ActionGroupWithSingleParameterSelectorFromPassedArgument(AcceptanceTester $I)
{
$I->comment("Entering Action Group actionGroupWithSingleParameterSelectorFromArgument (actionGroup)");
$I->see("Doe", "#element .John" . msq("UniquePerson"));
$I->comment("Exiting Action Group actionGroupWithSingleParameterSelectorFromArgument (actionGroup)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ class ActionGroupWithStepKeyReferencesCest
*/
public function ActionGroupWithStepKeyReferences(AcceptanceTester $I)
{
$I->comment("Entering Action Group FunctionActionGroupWithStepKeyReferences (actionGroup)");
$I->amGoingTo("create entity that has the stepKey: createSimpleDataActionGroup");
PersistedObjectHandler::getInstance()->createEntity(
"createSimpleDataActionGroup",
Expand Down Expand Up @@ -83,5 +84,6 @@ class ActionGroupWithStepKeyReferencesCest
$action14ActionGroup = $I->grabMultiple($action14ActionGroup);
$action15ActionGroup = $I->grabTextFrom($action15ActionGroup);
$action16ActionGroup = $I->grabValueFrom($action16ActionGroup);
$I->comment("Exiting Action Group FunctionActionGroupWithStepKeyReferences (actionGroup)");
}
}
Loading