You are here

public function DedupeEntityTest::providerTestDedupe in Zircon Profile 8.0

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

Data provider for testDedupe().

File

core/modules/migrate/tests/src/Unit/process/DedupeEntityTest.php, line 113
Contains \Drupal\Tests\migrate\Unit\process\DedupeEntityTest.

Class

DedupeEntityTest
@coversDefaultClass \Drupal\migrate\Plugin\migrate\process\DedupeEntity @group migrate

Namespace

Drupal\Tests\migrate\Unit\process

Code

public function providerTestDedupe() {
  return array(
    // Tests no duplication.
    array(
      0,
    ),
    // Tests no duplication and start position.
    array(
      0,
      NULL,
      10,
    ),
    // Tests no duplication, start position, and length.
    array(
      0,
      NULL,
      5,
      10,
    ),
    // Tests no duplication and length.
    array(
      0,
      NULL,
      NULL,
      10,
    ),
    // Tests duplication.
    array(
      3,
    ),
    // Tests duplication and start position.
    array(
      3,
      NULL,
      10,
    ),
    // Tests duplication, start position, and length.
    array(
      3,
      NULL,
      5,
      10,
    ),
    // Tests duplication and length.
    array(
      3,
      NULL,
      NULL,
      10,
    ),
    // Tests no duplication and postfix.
    array(
      0,
      '_',
    ),
    // Tests no duplication, postfix, and start position.
    array(
      0,
      '_',
      5,
    ),
    // Tests no duplication, postfix, start position, and length.
    array(
      0,
      '_',
      5,
      10,
    ),
    // Tests no duplication, postfix, and length.
    array(
      0,
      '_',
      NULL,
      10,
    ),
    // Tests duplication and postfix.
    array(
      2,
      '_',
    ),
    // Tests duplication, postfix, and start position.
    array(
      2,
      '_',
      5,
    ),
    // Tests duplication, postfix, start position, and length.
    array(
      2,
      '_',
      5,
      10,
    ),
    // Tests duplication, postfix, and length.
    array(
      2,
      '_',
      NULL,
      10,
    ),
  );
}