[TASK] Make MethodArgumentUnusedMatcherTest notice free 91/56191/3
authorJan Helke <typo3@helke.de>
Thu, 15 Mar 2018 19:50:02 +0000 (20:50 +0100)
committerChristian Kuhn <lolli@schwarzbu.ch>
Thu, 15 Mar 2018 20:36:54 +0000 (21:36 +0100)
Releases: master
Resolves: #84318
Change-Id: I04cf297b740ec6022a70f8b48d4d7be48e72854b
Reviewed-on: https://review.typo3.org/56191
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
typo3/sysext/install/Tests/Unit/ExtensionScanner/Php/Matcher/MethodArgumentUnusedMatcherTest.php

index ddbcbe2..8a5132d 100644 (file)
@@ -27,11 +27,6 @@ use TYPO3\TestingFramework\Core\Unit\UnitTestCase;
 class MethodArgumentUnusedMatcherTest extends UnitTestCase
 {
     /**
-     * Subject is not notice free, disable E_NOTICES
-     */
-    protected static $suppressNotices = true;
-
-    /**
      * @test
      */
     public function hitsFromFixtureAreFound()
@@ -233,6 +228,10 @@ class MethodArgumentUnusedMatcherTest extends UnitTestCase
         $traverser->traverse($statements);
 
         $result = $subject->getMatches();
-        $this->assertEquals($expected[0]['restFiles'], $result[0]['restFiles']);
+        if (isset($expected[0], $result[0])) {
+            $this->assertEquals($expected[0]['restFiles'], $result[0]['restFiles']);
+        } else {
+            $this->assertEquals($expected, $result);
+        }
     }
 }