Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / vendor / psy / psysh / test / CodeCleaner / StrictTypesPassTest.php
similarity index 74%
rename from vendor/psy/psysh/test/Psy/Test/CodeCleaner/StrictTypesPassTest.php
rename to vendor/psy/psysh/test/CodeCleaner/StrictTypesPassTest.php
index 8458fc01ba413d5912098e7d6a47f46e44d852a0..ee147824ad5bbca71313635b3da424be94721920 100644 (file)
@@ -3,7 +3,7 @@
 /*
  * This file is part of Psy Shell.
  *
- * (c) 2012-2017 Justin Hileman
+ * (c) 2012-2018 Justin Hileman
  *
  * For the full copyright and license information, please view the LICENSE
  * file that was distributed with this source code.
@@ -36,18 +36,17 @@ class StrictTypesPassTest extends CodeCleanerTestCase
      * @dataProvider invalidDeclarations
      * @expectedException \Psy\Exception\FatalErrorException
      */
-    public function testInvalidDeclarations($declaration)
+    public function testInvalidDeclarations($code)
     {
-        $stmts = $this->parse($declaration);
-        $this->traverser->traverse($stmts);
+        $this->parseAndTraverse($code);
     }
 
     public function invalidDeclarations()
     {
-        return array(
-            array('declare(strict_types=-1)'),
-            array('declare(strict_types=2)'),
-            array('declare(strict_types="foo")'),
-        );
+        return [
+            ['declare(strict_types=-1)'],
+            ['declare(strict_types=2)'],
+            ['declare(strict_types="foo")'],
+        ];
     }
 }