public function FileDownloadLinkMediaApplicableTest::testApplicableAll in File Download Link 8
This should not work for all until I delete oembed media type.
File
- tests/
src/ Kernel/ FileDownloadLinkMediaApplicableTest.php, line 101
Class
- FileDownloadLinkMediaApplicableTest
- Class for testing file_download_link_media formatter.
Namespace
Drupal\Tests\file_download_link\KernelCode
public function testApplicableAll() {
$field_definition = $this->node
->getFieldDefinition('field_all');
Assert::assertFalse(FileDownloadLinkMedia::isApplicable($field_definition));
$oembed = MediaType::load('oembed_media');
$oembed
->delete();
Assert::assertTrue(FileDownloadLinkMedia::isApplicable($field_definition));
}