Skip test if running as superuser as it will fail

This commit is contained in:
Miha Vrhovnik 2011-10-08 14:10:49 +02:00
parent 3d64d8e70f
commit 438581deda

View File

@ -79,6 +79,10 @@ class MimeTypeTest extends \PHPUnit_Framework_TestCase
$this->markTestSkipped('Can not verify chmod operations on Windows');
}
if (in_array(get_current_user(), array('root'))) {
$this->markTestSkipped('This test will fail if run under superuser');
}
$path = __DIR__.'/../Fixtures/to_delete';
touch($path);
chmod($path, 0333);