function EntityStorageBaseTest::providerLoad

Same name and namespace in other branches
  1. 9 core/tests/Drupal/Tests/Core/Entity/EntityStorageBaseTest.php \Drupal\Tests\Core\Entity\EntityStorageBaseTest::providerLoad()
  2. 11.x core/tests/Drupal/Tests/Core/Entity/EntityStorageBaseTest.php \Drupal\Tests\Core\Entity\EntityStorageBaseTest::providerLoad()

Data provider for testLoad().

File

core/tests/Drupal/Tests/Core/Entity/EntityStorageBaseTest.php, line 37

Class

EntityStorageBaseTest
@coversDefaultClass \Drupal\Core\Entity\EntityStorageBase[[api-linebreak]] @group Entity

Namespace

Drupal\Tests\Core\Entity

Code

public static function providerLoad() : \Generator {
  // Data set for a matching value.
  (yield 'matching-value' => [
    '1',
    [
      '1' => '1',
    ],
    '1',
  ]);
  // Data set for no matching value.
  (yield 'no-matching-value' => [
    NULL,
    [],
    '0',
  ]);
}

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