Updated to Drupal 8.6.4, which is PHP 7.3 friendly. Also updated HTMLaw library....
[yaffs-website] / web / core / tests / Drupal / Tests / Component / Utility / NestedArrayTest.php
index 0371ebb3503d0d261e808c75baceec9759ad1a9c..4cdb1b62f007ecd8e8c100ab250d50a427c836d4 100644 (file)
@@ -3,13 +3,13 @@
 namespace Drupal\Tests\Component\Utility;
 
 use Drupal\Component\Utility\NestedArray;
-use Drupal\Tests\UnitTestCase;
+use PHPUnit\Framework\TestCase;
 
 /**
  * @coversDefaultClass \Drupal\Component\Utility\NestedArray
  * @group Utility
  */
-class NestedArrayTest extends UnitTestCase {
+class NestedArrayTest extends TestCase {
 
   /**
    * Form array to check.
@@ -265,16 +265,24 @@ class NestedArrayTest extends UnitTestCase {
   public function providerTestFilter() {
     $data = [];
     $data['1d-array'] = [
-      [0, 1, '', TRUE], NULL, [1 => 1, 3 => TRUE]
+      [0, 1, '', TRUE], NULL, [1 => 1, 3 => TRUE],
     ];
     $data['1d-array-callable'] = [
-      [0, 1, '', TRUE], function ($element) { return $element === ''; }, [2 => '']
+      [0, 1, '', TRUE],
+      function ($element) {
+        return $element === '';
+      },
+      [2 => ''],
     ];
     $data['2d-array'] = [
       [[0, 1, '', TRUE], [0, 1, 2, 3]], NULL, [0 => [1 => 1, 3 => TRUE], 1 => [1 => 1, 2 => 2, 3 => 3]],
     ];
     $data['2d-array-callable'] = [
-      [[0, 1, '', TRUE], [0, 1, 2, 3]], function ($element) { return is_array($element) || $element === 3; }, [0 => [], 1 => [3 => 3]],
+      [[0, 1, '', TRUE], [0, 1, 2, 3]],
+      function ($element) {
+        return is_array($element) || $element === 3;
+      },
+      [0 => [], 1 => [3 => 3]],
     ];
 
     return $data;