File tree Expand file tree Collapse file tree 2 files changed +10
-5
lines changed
src/Magento/FunctionalTestingFramework/StaticCheck Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -494,12 +494,15 @@ vendor/bin/mftf static-checks testDependencies
494
494
``` bash
495
495
vendor/bin/mftf static-checks actionGroupArguments
496
496
```
497
+ ``` bash
498
+ vendor/bin/mftf static-checks testDependencies actionGroupArguments
499
+ ```
497
500
498
501
#### Existing static checks
499
502
500
503
* Test Dependency: Checks that test dependencies do not violate Magento module's composer dependencies.
501
- * Unused Arguments: Checks that action groups do not have unused arguments.
502
-
504
+ * Action Group Unused Arguments: Checks that action groups do not have unused arguments.
505
+
503
506
### ` upgrade:tests `
504
507
505
508
Applies all the MFTF major version upgrade scripts to test components in the given path (` test.xml ` , ` data.xml ` , etc).
Original file line number Diff line number Diff line change 7
7
namespace Magento \FunctionalTestingFramework \StaticCheck ;
8
8
9
9
use Magento \FunctionalTestingFramework \Config \MftfApplicationConfig ;
10
+ use Magento \FunctionalTestingFramework \Exceptions \XmlException ;
10
11
use Magento \FunctionalTestingFramework \Test \Handlers \ActionGroupObjectHandler ;
11
12
use Magento \FunctionalTestingFramework \Test \Objects \ActionGroupObject ;
12
13
use Symfony \Component \Console \Input \InputInterface ;
@@ -138,9 +139,10 @@ private function findUnusedArguments($actionGroupXml)
138
139
139
140
preg_match_all (self ::ACTIONGROUP_ARGUMENT_REGEX_PATTERN , $ actionGroupXml , $ arguments );
140
141
preg_match (self ::ACTIONGROUP_NAME_REGEX_PATTERN , $ actionGroupXml , $ actionGroupName );
141
-
142
- $ actionGroup = ActionGroupObjectHandler::getInstance ()->getObject ($ actionGroupName [1 ]);
143
-
142
+ try {
143
+ $ actionGroup = ActionGroupObjectHandler::getInstance ()->getObject ($ actionGroupName [1 ]);
144
+ } catch (XmlException $ e ){
145
+ }
144
146
foreach ($ arguments [1 ] as $ argument ) {
145
147
//pattern to match all argument references
146
148
$ patterns = [
You can’t perform that action at this time.
0 commit comments