[TASK] Remove checks for vfsStream availability 01/59401/2
authorStefanos Karasavvidis <sk@karasavvidis.gr>
Fri, 11 Jan 2019 09:26:38 +0000 (11:26 +0200)
committerMathias Brodala <mbrodala@pagemachine.de>
Fri, 11 Jan 2019 09:40:12 +0000 (10:40 +0100)
vfsStream and it's classes and methods are required anyway
and thus there is no need to check for it's existence.

Resolves: #87397
Releases: master
Change-Id: I342c3690217823d138ab98a00692de055f8d7fe8
Reviewed-on: https://review.typo3.org/59401
Tested-by: TYPO3com <noreply@typo3.com>
Reviewed-by: Mathias Brodala <mbrodala@pagemachine.de>
Tested-by: Mathias Brodala <mbrodala@pagemachine.de>
typo3/sysext/core/Tests/Unit/Cache/Backend/FileBackendTest.php
typo3/sysext/core/Tests/Unit/Log/Writer/FileWriterTest.php
typo3/sysext/core/Tests/Unit/Resource/BaseTestCase.php
typo3/sysext/core/Tests/Unit/Utility/GeneralUtilityTest.php

index 55c706e..3579300 100644 (file)
@@ -37,10 +37,6 @@ class FileBackendTest extends UnitTestCase
      */
     protected function setUp(): void
     {
-        if (!class_exists(vfsStreamWrapper::class)) {
-            $this->markTestSkipped('File backend tests are not available with this phpunit version.');
-        }
-
         vfsStreamWrapper::register();
         vfsStreamWrapper::setRoot(new vfsStreamDirectory('Foo'));
     }
index 01e16a9..304a102 100644 (file)
@@ -41,9 +41,6 @@ class FileWriterTest extends UnitTestCase
 
     protected function setUpVfsStream(): void
     {
-        if (!class_exists('org\\bovigo\\vfs\\vfsStream')) {
-            $this->markTestSkipped('File backend tests are not available with this phpunit version.');
-        }
         vfsStream::setup('LogRoot');
     }
 
index 81af1ee..074e85c 100644 (file)
@@ -53,9 +53,6 @@ abstract class BaseTestCase extends UnitTestCase
 
     protected function initializeVfs()
     {
-        if (is_callable('org\\bovigo\\vfs\\vfsStream::create') === false) {
-            $this->markTestSkipped('vfsStream::create() does not exist');
-        }
         vfsStream::create($this->vfsContents);
     }
 
index f532397..8f64619 100644 (file)
@@ -3025,9 +3025,6 @@ class GeneralUtilityTest extends UnitTestCase
      */
     public function mkdirDeepCreatesDirectoryInVfsStream()
     {
-        if (!class_exists('org\\bovigo\\vfs\\vfsStreamWrapper')) {
-            $this->markTestSkipped('mkdirDeepCreatesDirectoryInVfsStream() test not available with this phpunit version.');
-        }
         vfsStreamWrapper::register();
         $baseDirectory = $this->getUniqueId('test_');
         vfsStreamWrapper::setRoot(new vfsStreamDirectory($baseDirectory));
@@ -3197,9 +3194,6 @@ class GeneralUtilityTest extends UnitTestCase
      */
     protected function getFilesInDirCreateTestDirectory()
     {
-        if (!class_exists('org\\bovigo\\vfs\\vfsStreamWrapper')) {
-            $this->markTestSkipped('getFilesInDirCreateTestDirectory() helper method not available without vfsStream.');
-        }
         $structure = [
             'subDirectory' => [
                 'test.php' => 'butter',