You are here

public function CallbackTest::providerCallbackArray in Drupal 10

Same name and namespace in other branches
  1. 9 core/modules/migrate/tests/src/Unit/process/CallbackTest.php \Drupal\Tests\migrate\Unit\process\CallbackTest::providerCallbackArray()

Data provider for ::testCallbackArray().

File

core/modules/migrate/tests/src/Unit/process/CallbackTest.php, line 52

Class

CallbackTest
Tests the callback process plugin.

Namespace

Drupal\Tests\migrate\Unit\process

Code

public function providerCallbackArray() {
  return [
    'date format' => [
      'date',
      [
        'Y-m-d',
        995328000,
      ],
      '2001-07-17',
    ],
    'rtrim' => [
      'rtrim',
      [
        'https://www.example.com/',
        '/',
      ],
      'https://www.example.com',
    ],
    'str_replace' => [
      'str_replace',
      [
        [
          'One',
          'two',
        ],
        [
          '1',
          '2',
        ],
        'One, two, three!',
      ],
      '1, 2, three!',
    ],
    'pi' => [
      'pi',
      [],
      pi(),
    ],
  ];
}