public function FieldOutputTest::testEmbedField in Video Embed Field 8
Same name and namespace in other branches
- 8.2 tests/src/Kernel/FieldOutputTest.php \Drupal\Tests\video_embed_field\Kernel\FieldOutputTest::testEmbedField()
Test the embed field.
@dataProvider renderedFieldTestCases
File
- tests/
src/ Kernel/ FieldOutputTest.php, line 563
Class
- FieldOutputTest
- Test the embed field formatters are functioning.
Namespace
Drupal\Tests\video_embed_field\KernelCode
public function testEmbedField($url, $settings, $expected_field_item_output) {
$field_output = $this
->getPreparedFieldOutput($url, $settings);
// Assert the specific field output at delta 1 matches the expected test
// data.
$this
->assertEquals($expected_field_item_output, $field_output[0]);
}