function FontWeightTest::providerToCss

Data provider for ::testToCss().

Return value

\Generator The test cases.

File

core/tests/Drupal/Tests/Core/Theme/DesignToken/Plugin/FontWeightTest.php, line 87

Class

FontWeightTest
Tests font weight value plugin.

Namespace

Drupal\Tests\Core\Theme\DesignToken\Plugin

Code

public static function providerToCss() : iterable {
  foreach (FontWeightAlias::cases() as $case) {
    yield $case->name => [
      $case->value,
      (string) $case->value(),
    ];
  }
  yield 'integer' => [
    50,
    '50',
  ];
  yield 'minimum' => [
    1,
    '1',
  ];
  yield 'maximum' => [
    1000,
    '1000',
  ];
}

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