function MimeTypeMapTest::testRemoveMapping
@covers ::removeMapping
File
-
core/
tests/ Drupal/ Tests/ Core/ File/ MimeType/ MimeTypeMapTest.php, line 52
Class
- MimeTypeMapTest
- Tests the MIME type mapper to extension.
Namespace
Drupal\Tests\Core\File\MimeTypeCode
public function testRemoveMapping() : void {
$this->assertTrue($this->map
->removeMapping('image/jpeg', 'jpg'));
$this->assertNull($this->map
->getMimeTypeForExtension('jpg'));
$this->assertFalse($this->map
->removeMapping('bar', 'foo'));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.