function TypographyTest::testToDtcg

Attributes

#[DataProvider('providerToDtcg')]

File

core/tests/Drupal/Tests/Core/Theme/DesignToken/Plugin/TypographyTest.php, line 50

Class

TypographyTest
Tests typography value plugin.

Namespace

Drupal\Tests\Core\Theme\DesignToken\Plugin

Code

public function testToDtcg(mixed $value, mixed $expected) : void {
  $this->assertIsArray($value);
  $this->assertIsArray($expected);
  $this->setupContainer($value);
  $plugin = new Typography($value, $this->pluginId, [], \Drupal::service(DesignTokenValuePluginManagerInterface::class));
  $this->assertSame($expected, $plugin->toDtcg());
}

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