You are here

public function UiPatternsPreviewTest::testProcessContext in UI Patterns 8

Test processContext.

@dataProvider processContextDataProvider

@covers ::processContext

File

tests/src/Kernel/UiPatternsPreviewTest.php, line 34

Class

UiPatternsPreviewTest
@coversDefaultClass \Drupal\ui_patterns\Element\PatternPreview

Namespace

Drupal\Tests\ui_patterns\Unit\Element

Code

public function testProcessContext($render, $expected) {
  $this
    ->renderRoot($render);
  $this
    ->assertEquals($expected, $render["#context"]
    ->getType());
}