You are here

public function EntityUrlTest::providerTestToUrlLinkTemplateAddForm in Drupal 10

Same name and namespace in other branches
  1. 8 core/tests/Drupal/Tests/Core/Entity/EntityUrlTest.php \Drupal\Tests\Core\Entity\EntityUrlTest::providerTestToUrlLinkTemplateAddForm()
  2. 9 core/tests/Drupal/Tests/Core/Entity/EntityUrlTest.php \Drupal\Tests\Core\Entity\EntityUrlTest::providerTestToUrlLinkTemplateAddForm()

Provides data for testToUrlLinkTemplateAddForm().

Return value

array An array of test cases for testToUrlLinkTemplateAddForm().

File

core/tests/Drupal/Tests/Core/Entity/EntityUrlTest.php, line 286

Class

EntityUrlTest
Tests URL handling of the \Drupal\Core\Entity\EntityBase class.

Namespace

Drupal\Tests\Core\Entity

Code

public function providerTestToUrlLinkTemplateAddForm() {
  $test_cases = [];
  $route_parameters = [];
  $test_cases['no_bundle_key'] = [
    static::HAS_NO_BUNDLE_KEY,
    NULL,
    FALSE,
    $route_parameters,
  ];
  $route_parameters = [
    'type' => $this->entityTypeId,
  ];
  $test_cases['bundle_entity_type'] = [
    static::HAS_BUNDLE_KEY,
    'type',
    FALSE,
    $route_parameters,
  ];
  $test_cases['bundle_key'] = [
    static::HAS_BUNDLE_KEY,
    NULL,
    'type',
    $route_parameters,
  ];
  return $test_cases;
}