Skip to content

Commit

Permalink
Merge pull request #323 from magento-commerce/suite-hotfix
Browse files Browse the repository at this point in the history
Suite hotfix
  • Loading branch information
okolesnyk authored Aug 15, 2023
2 parents 518bfbc + 00e1508 commit 0f30611
Show file tree
Hide file tree
Showing 7 changed files with 35 additions and 10 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
Magento Functional Testing Framework Changelog
================================================

4.3.4
---------
### Fixes
* Resolving an issue when test is marked as failed due to Suite after section failure

4.3.3
---------
### Enhancements
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "magento/magento2-functional-testing-framework",
"description": "Magento2 Functional Testing Framework",
"type": "library",
"version": "4.3.3",
"version": "4.3.4",
"license": "AGPL-3.0",
"keywords": ["magento", "automation", "functional", "testing"],
"config": {
Expand Down
2 changes: 1 addition & 1 deletion composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -196,8 +196,13 @@ class ActionsInDifferentModulesSuite extends \Codeception\GroupObject
);
$availableSessions = RemoteWebDriver::getAllSessions($wdHost);
foreach ($availableSessions as $session) {
$remoteWebDriver = RemoteWebDriver::createBySessionID($session['id'], $wdHost);
$remoteWebDriver->quit();
try {
$remoteWebDriver = RemoteWebDriver::createBySessionID($session['id'], $wdHost);
$remoteWebDriver->quit();
} catch (\Exception $exception) {
print("Failed trying to quit WebDriver session. Exception message: " . $exception->getMessage() . " Test execution will continue." . PHP_EOL);
// Session already closed so nothing to do
}
}
}
}
Expand Down
9 changes: 7 additions & 2 deletions dev/tests/verification/Resources/functionalSuiteHooks.txt
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,13 @@ class functionalSuiteHooks extends \Codeception\GroupObject
);
$availableSessions = RemoteWebDriver::getAllSessions($wdHost);
foreach ($availableSessions as $session) {
$remoteWebDriver = RemoteWebDriver::createBySessionID($session['id'], $wdHost);
$remoteWebDriver->quit();
try {
$remoteWebDriver = RemoteWebDriver::createBySessionID($session['id'], $wdHost);
$remoteWebDriver->quit();
} catch (\Exception $exception) {
print("Failed trying to quit WebDriver session. Exception message: " . $exception->getMessage() . " Test execution will continue." . PHP_EOL);
// Session already closed so nothing to do
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -159,8 +159,13 @@ class functionalSuiteWithComments extends \Codeception\GroupObject
);
$availableSessions = RemoteWebDriver::getAllSessions($wdHost);
foreach ($availableSessions as $session) {
$remoteWebDriver = RemoteWebDriver::createBySessionID($session['id'], $wdHost);
$remoteWebDriver->quit();
try {
$remoteWebDriver = RemoteWebDriver::createBySessionID($session['id'], $wdHost);
$remoteWebDriver->quit();
} catch (\Exception $exception) {
print("Failed trying to quit WebDriver session. Exception message: " . $exception->getMessage() . " Test execution will continue." . PHP_EOL);
// Session already closed so nothing to do
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,13 @@ class {{suiteName}} extends \Codeception\GroupObject
);
$availableSessions = RemoteWebDriver::getAllSessions($wdHost);
foreach ($availableSessions as $session) {
$remoteWebDriver = RemoteWebDriver::createBySessionID($session['id'], $wdHost);
$remoteWebDriver->quit();
try {
$remoteWebDriver = RemoteWebDriver::createBySessionID($session['id'], $wdHost);
$remoteWebDriver->quit();
} catch (\Exception $exception) {
print("Failed trying to quit WebDriver session. Exception message: " . $exception->getMessage() . " Test execution will continue." . PHP_EOL);
// Session already closed so nothing to do
}
}
}
}
Expand Down

0 comments on commit 0f30611

Please sign in to comment.