Skip to content

Commit 4074560

Browse files
committed
MQE-659: [ALLURE] Include the test "stepKey" in the MFTF Allure Report
1 parent 17b8b9d commit 4074560

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

src/Magento/FunctionalTestingFramework/Allure/Adapter/MagentoAllureAdapter.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -198,11 +198,9 @@ public function testEnd()
198198

199199
$actionGroupStepKey = null;
200200
foreach ($rootStep->getSteps() as $step) {
201-
if ($actionGroupStepKey !== null) {
202-
$stepKey = str_replace($actionGroupStepKey, '', $step->getName());
203-
if ($stepKey !== '[]' && $stepKey !== null) {
204-
$step->setName($stepKey);
205-
}
201+
$stepKey = str_replace($actionGroupStepKey, '', $step->getName());
202+
if ($stepKey !== '[]' && $stepKey !== null) {
203+
$step->setName($stepKey);
206204
}
207205
// if actionGroup flag, start nesting
208206
if (strpos($step->getName(), ActionGroupObject::ACTION_GROUP_CONTEXT_START) !== false) {

src/Magento/FunctionalTestingFramework/Codeception/Subscriber/Console.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
<?php
2+
/**
3+
* Copyright © Magento, Inc. All rights reserved.
4+
* See COPYING.txt for license details.
5+
*/
6+
27
namespace Magento\FunctionalTestingFramework\Codeception\Subscriber;
38

49
use Codeception\Event\StepEvent;
@@ -68,6 +73,7 @@ public function afterStep(StepEvent $e)
6873
*
6974
* @param Step $step
7075
* @return void
76+
* @SuppressWarnings(PHPMD)
7177
*/
7278
private function printStepKeys(Step $step)
7379
{

0 commit comments

Comments
 (0)