function BlockSettingsTest::providerTestTransform

Same name and namespace in other branches
  1. 9 core/modules/block/tests/src/Unit/Plugin/migrate/process/BlockSettingsTest.php \Drupal\Tests\block\Unit\Plugin\migrate\process\BlockSettingsTest::providerTestTransform()
  2. 11.x core/modules/block/tests/src/Unit/Plugin/migrate/process/BlockSettingsTest.php \Drupal\Tests\block\Unit\Plugin\migrate\process\BlockSettingsTest::providerTestTransform()

Provides data for testTransform.

File

core/modules/block/tests/src/Unit/Plugin/migrate/process/BlockSettingsTest.php, line 43

Class

BlockSettingsTest
@coversDefaultClass \Drupal\block\Plugin\migrate\process\BlockSettings[[api-linebreak]] @group block

Namespace

Drupal\Tests\block\Unit\Plugin\migrate\process

Code

public static function providerTestTransform() {
  return [
    'title set' => [
      [
        'custom',
        0,
        'foo',
        'title',
      ],
      [
        'label' => 'title',
        'label_display' => 'visible',
      ],
    ],
    'title empty' => [
      [
        'custom',
        0,
        'foo',
        '',
      ],
      [
        'label' => '',
        'label_display' => '0',
      ],
    ],
    'title <none>' => [
      [
        'custom',
        0,
        'foo',
        '<none>',
      ],
      [
        'label' => '<none>',
        'label_display' => '0',
      ],
    ],
  ];
}

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