You are here

public function HttpMimeTypeGuesserTest::testParseFileNameFromUrl in Remote Stream Wrapper 8

Test the mime type guessing with various HTTP URLs.

@covers ::parseFileNameFromUrl @dataProvider dataParseFileNameFromUrl

File

tests/src/Kernel/HttpMimeTypeGuesserTest.php, line 47

Class

HttpMimeTypeGuesserTest
@coversDefaultClass \Drupal\remote_stream_wrapper\File\MimeType\HttpMimeTypeGuesser @group remote_stream_wrapper

Namespace

Drupal\Tests\remote_stream_wrapper\Kernel

Code

public function testParseFileNameFromUrl($url, $expected_result) {
  $this
    ->assertEquals($expected_result, $this->httpGuesser
    ->parseFileNameFromUrl($url));
}