public function FileLinkValidationTest::testWithoutExtension in File Link 8
Same name and namespace in other branches
- 2.0.x tests/src/Kernel/FileLinkValidationTest.php \Drupal\Tests\file_link\Kernel\FileLinkValidationTest::testWithoutExtension()
Tests file_link field metadata storage without extension.
File
- tests/
src/ Kernel/ FileLinkValidationTest.php, line 82
Class
- FileLinkValidationTest
- Provides kernel tests for 'file_link' field type.
Namespace
Drupal\Tests\file_link\KernelCode
public function testWithoutExtension() {
$this->entity
->set('url_without_extension', [
'uri' => static::getFullUrl(''),
]);
$violations = $this->entity
->get('url_without_extension')
->validate();
$this
->assertSame(0, $violations
->count());
}