function GetTest::integerValuesDataProvider

Same name and namespace in other branches
  1. 9 core/modules/migrate/tests/src/Unit/process/GetTest.php \Drupal\Tests\migrate\Unit\process\GetTest::integerValuesDataProvider()
  2. 8.9.x core/modules/migrate/tests/src/Unit/process/GetTest.php \Drupal\Tests\migrate\Unit\process\GetTest::integerValuesDataProvider()
  3. 10 core/modules/migrate/tests/src/Unit/process/GetTest.php \Drupal\Tests\migrate\Unit\process\GetTest::integerValuesDataProvider()

Provides data for the successful lookup test.

Return value

array

File

core/modules/migrate/tests/src/Unit/process/GetTest.php, line 100

Class

GetTest
Tests the get process plugin.

Namespace

Drupal\Tests\migrate\Unit\process

Code

public static function integerValuesDataProvider() {
    return [
        [
            'source' => [
                0 => 0,
                1 => 'test',
            ],
            'expected_value' => [
                0 => 'val1',
                1 => 'val2',
            ],
        ],
        [
            'source' => [
                FALSE,
            ],
            'expected_value' => [
                NULL,
            ],
        ],
        [
            'source' => [
                NULL,
            ],
            'expected_value' => [
                NULL,
            ],
        ],
    ];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.