Skip to content

Commit acb640e

Browse files
committed
Skip MIME Type test if MIME_Type is not available.
It only ever will be available for someone who has MIME_Type installed in such a way that it will be autoloaded correctly. I'm not sure that is even possible so this may make this test a noop. MIME_Type never will be available on Travis without work and this Detector will likely be phased out before that work can be done so this test will always be skipped on Travis.
1 parent 4da1bed commit acb640e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

test/Versionable/Ferret/Detector/MIMETypeTest.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@ class MIMETypeTest extends \PHPUnit_Framework_TestCase {
2222
* This method is called before a test is executed.
2323
*/
2424
protected function setUp() {
25+
if (!class_exists('MIME_Type')) {
26+
$this->markTestSkipped("Requires PEAR MIME_Type");
27+
}
28+
2529
$this->object = new MIMEType;
2630
}
2731

0 commit comments

Comments
 (0)