ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilMimeTypeTest Class Reference

Class ilMimeTypeTest. More...

+ Inheritance diagram for ilMimeTypeTest:
+ Collaboration diagram for ilMimeTypeTest:

Public Member Functions

 testMimeTypeForYoutubeUrlCouldBeCorrectlyDetected ()
 
 testMimeTypeForVimeoUrlCouldBeCorrectlyDetected ()
 

Detailed Description

Class ilMimeTypeTest.

Definition at line 7 of file ilMimeTypeTest.php.

Member Function Documentation

◆ testMimeTypeForVimeoUrlCouldBeCorrectlyDetected()

ilMimeTypeTest::testMimeTypeForVimeoUrlCouldBeCorrectlyDetected ( )

Definition at line 26 of file ilMimeTypeTest.php.

27 {
28 $expected = 'video/vimeo';
30 'https://vimeo.com/180157999',
32 );
33
34 $this->assertEquals($expected, $actual);
35 }
static lookupMimeType($path_to_file, $fallback=self::APPLICATION__OCTET_STREAM, $a_external=null)

References ilMimeTypeUtil\APPLICATION__OCTET_STREAM, and ilMimeTypeUtil\lookupMimeType().

+ Here is the call graph for this function:

◆ testMimeTypeForYoutubeUrlCouldBeCorrectlyDetected()

ilMimeTypeTest::testMimeTypeForYoutubeUrlCouldBeCorrectlyDetected ( )

Definition at line 12 of file ilMimeTypeTest.php.

13 {
14 $expected = 'video/youtube';
16 'https://www.youtube.com/watch?v=WSgP85kr6eU',
18 );
19
20 $this->assertEquals($expected, $actual);
21 }

References ilMimeTypeUtil\APPLICATION__OCTET_STREAM, and ilMimeTypeUtil\lookupMimeType().

+ Here is the call graph for this function:

The documentation for this class was generated from the following file: