function DesignTokenPluginManagerTest::testParseDtcg
Same name and namespace in other branches
- 11.x core/tests/Drupal/Tests/Core/Theme/DesignToken/DesignTokenPluginManagerTest.php \Drupal\Tests\Core\Theme\DesignToken\DesignTokenPluginManagerTest::testParseDtcg()
Tests parseDtcg.
Attributes
#[DataProvider('providerParseDtcg')]
File
-
core/
tests/ Drupal/ Tests/ Core/ Theme/ DesignToken/ DesignTokenPluginManagerTest.php, line 91
Class
- DesignTokenPluginManagerTest
- Tests design token plugin manager.
Namespace
Drupal\Tests\Core\Theme\DesignTokenCode
public function testParseDtcg(array $data, ?DtcgInterface $expected) : void {
$reflection = new \ReflectionClass($this->designTokenPluginManager);
$method = $reflection->getMethod('parseDtcg');
$this->assertEquals($expected, $method->invoke($this->designTokenPluginManager, 'test', 'root name', $data));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.