[TASK] Use name-resolution instead of strings where possible: 17 91/35091/2
authorMarkus Klein <klein.t3@reelworx.at>
Sat, 6 Dec 2014 01:40:57 +0000 (02:40 +0100)
committerAlexander Opitz <opitz.alexander@googlemail.com>
Mon, 8 Dec 2014 15:36:30 +0000 (16:36 +0100)
(miscellaneous)

Use name-resolution with ...::class instead of strings where possible.
(needs PHP 5.5, which is meanwhile required for master)

Change-set Iedbb896607adddce2b23ab67f990fa2296c0d1bb first introduced
usage of ::class in master. We now add it in various more places.

Resolves: #63477
Releases: master
Change-Id: Ifa4022cefef28dcfc4fae18e8aa003f6ade21cb3
Reviewed-on: http://review.typo3.org/35091
Reviewed-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Tested-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Reviewed-by: Alexander Opitz <opitz.alexander@googlemail.com>
Tested-by: Alexander Opitz <opitz.alexander@googlemail.com>
36 files changed:
typo3/sysext/backend/Classes/Controller/BackendController.php
typo3/sysext/core/Classes/Resource/Driver/LocalDriver.php
typo3/sysext/core/Classes/Utility/ExtensionManagementUtility.php
typo3/sysext/core/Classes/Utility/File/ExtendedFileUtility.php
typo3/sysext/core/Tests/Functional/Category/Collection/CategoryCollectionTest.php
typo3/sysext/core/Tests/Unit/Cache/Backend/ApcBackendTest.php
typo3/sysext/core/Tests/Unit/Cache/Backend/MemcachedBackendTest.php
typo3/sysext/core/Tests/Unit/Cache/Backend/WincacheBackendTest.php
typo3/sysext/core/Tests/Unit/Cache/Backend/XcacheBackendTest.php
typo3/sysext/core/Tests/Unit/Database/SqlParserTest.php
typo3/sysext/core/Tests/Unit/Log/Processor/AbstractProcessorTest.php
typo3/sysext/core/Tests/Unit/Log/Processor/IntrospectionProcessorTest.php
typo3/sysext/core/Tests/Unit/Package/DependencyResolverTest.php
typo3/sysext/core/Tests/Unit/Package/PackageManagerTest.php
typo3/sysext/core/Tests/Unit/Resource/Utility/FileExtensionFilterTest.php
typo3/sysext/core/Tests/Unit/TypoScript/TemplateServiceTest.php
typo3/sysext/core/Tests/Unit/Utility/ExtensionManagementUtilityTest.php
typo3/sysext/core/Tests/Unit/Utility/ResourceUtilityTest.php
typo3/sysext/core/Tests/Unit/Utility/RootlineUtilityTest.php
typo3/sysext/extbase/Tests/Functional/Fixtures/Extensions/blog_example/Classes/Domain/Repository/BlogRepository.php
typo3/sysext/extbase/Tests/Functional/Persistence/InTest.php
typo3/sysext/extbase/Tests/Unit/Mvc/Controller/AbstractControllerTest.php
typo3/sysext/extbase/Tests/Unit/Persistence/Generic/Mapper/DataMapFactoryTest.php
typo3/sysext/extbase/Tests/Unit/Scheduler/FieldProviderTest.php
typo3/sysext/extbase/Tests/Unit/Validation/Validator/CollectionValidatorTest.php
typo3/sysext/extbase/Tests/Unit/Validation/ValidatorResolverTest.php
typo3/sysext/extensionmanager/Tests/Unit/Controller/DownloadControllerTest.php
typo3/sysext/extensionmanager/Tests/Unit/Utility/InstallUtilityTest.php
typo3/sysext/frontend/Classes/ContentObject/Menu/CategoryMenuUtility.php
typo3/sysext/frontend/Tests/Unit/ContentObject/ContentObjectRendererTest.php
typo3/sysext/frontend/Tests/Unit/Controller/TypoScriptFrontendControllerTest.php
typo3/sysext/frontend/Tests/Unit/MediaWizard/MediaWizardProviderTest.php
typo3/sysext/install/Tests/Unit/FolderStructure/DirectoryNodeTest.php
typo3/sysext/install/Tests/Unit/FolderStructure/FileNodeTest.php
typo3/sysext/install/Tests/Unit/FolderStructure/LinkNodeTest.php
typo3/sysext/install/Tests/Unit/FolderStructure/RootNodeTest.php

index 74d5e11..bec4e63 100644 (file)
@@ -156,7 +156,7 @@ class BackendController {
                        if (!$toolbarItemInstance instanceof \TYPO3\CMS\Backend\Toolbar\ToolbarItemInterface) {
                                throw new \RuntimeException(
                                        'class ' . $className . ' is registered as toolbar item but does not implement'
-                                               . '\TYPO3\CMS\Backend\Toolbar\ToolbarItemInterface',
+                                               . \TYPO3\CMS\Backend\Toolbar\ToolbarItemInterface::class,
                                        1415958218
                                );
                        }
index e0b6c7a..54e589c 100644 (file)
@@ -362,7 +362,7 @@ class LocalDriver extends AbstractHierarchicalFilesystemDriver {
                $items = $this->retrieveFileAndFoldersInPath($realPath, $recursive, $includeFiles, $includeDirs);
                uksort(
                        $items,
-                       array('\\TYPO3\\CMS\\Core\\Utility\\ResourceUtility', 'recursiveFileListSortingHelper')
+                       array(\TYPO3\CMS\Core\Utility\ResourceUtility::class, 'recursiveFileListSortingHelper')
                );
 
                $iterator = new \ArrayIterator($items);
index 2588136..089103a 100644 (file)
@@ -770,7 +770,7 @@ class ExtensionManagementUtility {
                $moduleConfiguration['name'] = $moduleSignature;
                $moduleConfiguration['script'] = 'extjspaneldummy.html';
                $moduleConfiguration['extensionName'] = $extensionName;
-               $moduleConfiguration['configureModuleFunction'] = array(\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::class, 'configureModule');
+               $moduleConfiguration['configureModuleFunction'] = array(ExtensionManagementUtility::class, 'configureModule');
                $GLOBALS['TBE_MODULES']['_configuration'][$moduleSignature] = $moduleConfiguration;
                self::addModule($mainModuleName, $subModuleName, $position);
        }
@@ -1763,7 +1763,7 @@ tt_content.' . $key . $prefix . ' {
                                // Add ext_tables.php content of extension
                                $phpCodeToCache[] = trim(GeneralUtility::getUrl($extensionDetails['ext_tables.php']));
                                $phpCodeToCache[] = '';
-                               $phpCodeToCache[] = '\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::loadNewTcaColumnsConfigFiles();';
+                               $phpCodeToCache[] = ExtensionManagementUtility::class . '::loadNewTcaColumnsConfigFiles();';
                                $phpCodeToCache[] = '';
                        }
                }
@@ -1899,7 +1899,7 @@ tt_content.' . $key . $prefix . ' {
                // Update the category registry
                $result = CategoryRegistry::getInstance()->add($extensionKey, $tableName, $fieldName, $options);
                if ($result === FALSE) {
-                       $message = '\TYPO3\CMS\Core\Category\CategoryRegistry: no category registered for table "%s". Key was already registered.';
+                       $message = CategoryRegistry::class . ': no category registered for table "%s". Key was already registered.';
                        /** @var $logger \TYPO3\CMS\Core\Log\Logger */
                        $logger = GeneralUtility::makeInstance(\TYPO3\CMS\Core\Log\LogManager::class)->getLogger(__CLASS__);
                        $logger->warning(
index 2d8f717..cf84c34 100644 (file)
@@ -358,7 +358,7 @@ class ExtendedFileUtility extends BasicFileUtility {
 
                                // render a message that the file could not be deleted
                                $flashMessage = GeneralUtility::makeInstance(
-                                       '\\TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
+                                       FlashMessage::class,
                                        sprintf($GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:message.description.fileNotDeletedHasReferences'), $fileObject->getName()) . '<br />' . implode('<br />', $shortcutContent),
                                        $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:message.header.fileNotDeletedHasReferences'),
                                        FlashMessage::WARNING,
@@ -371,7 +371,7 @@ class ExtendedFileUtility extends BasicFileUtility {
 
                                        // show the user that the file was deleted
                                        $flashMessage = GeneralUtility::makeInstance(
-                                               '\\TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
+                                               FlashMessage::class,
                                                sprintf($GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:message.description.fileDeleted'), $fileObject->getName()),
                                                $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:message.header.fileDeleted'),
                                                FlashMessage::OK,
@@ -394,7 +394,7 @@ class ExtendedFileUtility extends BasicFileUtility {
                                if ($fileObject->getFileCount() > 0) {
                                        // render a message that the folder could not be deleted because it still contains files
                                        $flashMessage = GeneralUtility::makeInstance(
-                                               '\\TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
+                                               FlashMessage::class,
                                                sprintf($GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:message.description.folderNotDeletedHasFiles'), $fileObject->getName()),
                                                $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:message.header.folderNotDeletedHasFiles'),
                                                FlashMessage::WARNING,
@@ -406,7 +406,7 @@ class ExtendedFileUtility extends BasicFileUtility {
 
                                        // notify the user that the folder was deleted
                                        $flashMessage = GeneralUtility::makeInstance(
-                                               '\\TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
+                                               FlashMessage::class,
                                                sprintf($GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:message.description.folderDeleted'), $fileObject->getName()),
                                                $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:message.header.folderDeleted'),
                                                FlashMessage::OK,
@@ -947,7 +947,7 @@ class ExtendedFileUtility extends BasicFileUtility {
        /**
         * Add flash message to message queue
         *
-        * @param \TYPO3\CMS\Core\Messaging\FlashMessage $flashMessage
+        * @param FlashMessage $flashMessage
         * @return void
         */
        protected function addFlashMessage(FlashMessage $flashMessage) {
index 0e4deab..cac68c5 100644 (file)
@@ -101,7 +101,7 @@ class CategoryCollectionTest extends \TYPO3\CMS\Core\Tests\FunctionalTestCase {
         */
        public function canCreateDummyCollection() {
                $collection = \TYPO3\CMS\Core\Category\Collection\CategoryCollection::create($this->collectionRecord);
-               $this->assertInstanceOf('\TYPO3\CMS\Core\Category\Collection\CategoryCollection', $collection);
+               $this->assertInstanceOf(\TYPO3\CMS\Core\Category\Collection\CategoryCollection::class, $collection);
        }
 
        /**
@@ -111,7 +111,7 @@ class CategoryCollectionTest extends \TYPO3\CMS\Core\Tests\FunctionalTestCase {
         */
        public function canCreateDummyCollectionAndFillItems() {
                $collection = \TYPO3\CMS\Core\Category\Collection\CategoryCollection::create($this->collectionRecord, TRUE);
-               $this->assertInstanceOf('\TYPO3\CMS\Core\Category\Collection\CategoryCollection', $collection);
+               $this->assertInstanceOf(\TYPO3\CMS\Core\Category\Collection\CategoryCollection::class, $collection);
        }
 
        /**
index 13ac4b9..0ea0215 100644 (file)
@@ -144,7 +144,7 @@ class ApcBackendTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
 
                /** @var $backendMock \PHPUnit_Framework_MockObject_MockObject|ApcBackend */
                $backendMock = $this->getMock(
-                       \TYPO3\CMS\Core\Cache\Backend\ApcBackend::class,
+                       ApcBackend::class,
                        array('setIdentifierPrefix','getCurrentUserData','getPathSite'),
                        array('testcontext')
                );
@@ -279,7 +279,7 @@ class ApcBackendTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                /** @var \PHPUnit_Framework_MockObject_MockObject|\TYPO3\CMS\Core\Cache\Frontend\FrontendInterface $cache */
                $cache = $this->getMock(\TYPO3\CMS\Core\Cache\Frontend\FrontendInterface::class, array(), array(), '', FALSE);
                if ($accessible) {
-                       $accessibleClassName = $this->buildAccessibleProxy('\\TYPO3\\CMS\\Core\\Cache\\Backend\\ApcBackend');
+                       $accessibleClassName = $this->buildAccessibleProxy(ApcBackend::class);
                        $backend = new $accessibleClassName('Testing');
                } else {
                        $backend = new ApcBackend('Testing');
index 1cc66ea..ef7205c 100644 (file)
@@ -268,7 +268,7 @@ class MemcachedBackendTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                        $backendOptions = array('servers' => array('localhost:11211'));
                }
                if ($accessible) {
-                       $accessibleClassName = $this->buildAccessibleProxy('\\TYPO3\\CMS\\Core\\Cache\\Backend\\MemcachedBackend');
+                       $accessibleClassName = $this->buildAccessibleProxy(MemcachedBackend::class);
                        $backend = new $accessibleClassName('Testing', $backendOptions);
                } else {
                        $backend = new MemcachedBackend('Testing', $backendOptions);
index 893b127..9b3e4a3 100644 (file)
@@ -240,7 +240,7 @@ class WincacheBackendTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                /** @var \PHPUnit_Framework_MockObject_MockObject|\TYPO3\CMS\Core\Cache\Frontend\FrontendInterface $cache */
                $cache = $this->getMock(\TYPO3\CMS\Core\Cache\Frontend\FrontendInterface::class, array(), array(), '', FALSE);
                if ($accessible) {
-                       $accessibleClassName = $this->buildAccessibleProxy('\\TYPO3\\CMS\\Core\\Cache\\Backend\\WincacheBackend');
+                       $accessibleClassName = $this->buildAccessibleProxy(WincacheBackend::class);
                        $backend = new $accessibleClassName('Testing');
                } else {
                        $backend = new WincacheBackend('Testing');
index c313b8c..9a1c45e 100644 (file)
@@ -243,7 +243,7 @@ class XcacheBackendTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                /** @var \PHPUnit_Framework_MockObject_MockObject|\TYPO3\CMS\Core\Cache\Frontend\FrontendInterface $cache */
                $cache = $this->getMock(\TYPO3\CMS\Core\Cache\Frontend\FrontendInterface::class, array(), array(), '', FALSE);
                if ($accessible) {
-                       $accessibleClassName = $this->buildAccessibleProxy('\\TYPO3\\CMS\\Core\\Cache\\Backend\\XcacheBackend');
+                       $accessibleClassName = $this->buildAccessibleProxy(XcacheBackend::class);
                        $backend = new $accessibleClassName('Testing');
                } else {
                        $backend = new XcacheBackend('Testing');
index 95260d5..611a787 100644 (file)
@@ -26,7 +26,7 @@ class SqlParserTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
        protected $fixture;
 
        public function setUp() {
-               $this->fixture = $this->getAccessibleMock('\\TYPO3\\CMS\\Core\\Database\\SqlParser', array('dummy'));
+               $this->fixture = $this->getAccessibleMock(\TYPO3\CMS\Core\Database\SqlParser::class, array('dummy'));
        }
 
        /**
index c6c31be..e47e236 100644 (file)
@@ -29,7 +29,7 @@ class AbstractProcessorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $invalidConfiguration = array(
                        'foo' => 'bar'
                );
-               $processor = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Tests\Unit\Log\Fixtures\ProcessorFixture::class, $invalidConfiguration);
+               \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Tests\Unit\Log\Fixtures\ProcessorFixture::class, $invalidConfiguration);
        }
 
        /**
@@ -40,7 +40,7 @@ class AbstractProcessorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $writer = new \TYPO3\CMS\Core\Log\Writer\NullWriter();
                $level = \TYPO3\CMS\Core\Log\LogLevel::DEBUG;
                $logRecord = new \TYPO3\CMS\Core\Log\LogRecord('dummy', $level, 'message');
-               $processor = $this->getMock('\\TYPO3\\CMS\\Core\\Log\\Processor\\ProcessorInterface', array('processLogRecord'));
+               $processor = $this->getMock(\TYPO3\CMS\Core\Log\Processor\ProcessorInterface::class, array('processLogRecord'));
                $processor->expects($this->once())->method('processLogRecord')->willReturn($logRecord);
 
                $logger->addWriter($level, $writer);
index de25882..3ac4759 100644 (file)
@@ -61,7 +61,7 @@ class IntrospectionProcessorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
         */
        public function setUp() {
                $this->processor = $this->getAccessibleMock(
-                       '\TYPO3\CMS\Core\Log\Processor\IntrospectionProcessor',
+                       \TYPO3\CMS\Core\Log\Processor\IntrospectionProcessor::class,
                        array('getDebugBacktrace', 'formatDebugBacktrace')
                );
        }
@@ -171,4 +171,4 @@ class IntrospectionProcessorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $this->assertContains($this->dummyBacktrace[2], $logRecord['data']['backtrace']);
                $this->assertContains($this->dummyBacktrace[3], $logRecord['data']['backtrace']);
        }
-}
\ No newline at end of file
+}
index c9afedb..c19cf86 100644 (file)
@@ -38,7 +38,7 @@ class DependencyResolverTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                        array($unsortedPackageStatesConfiguration, DependencyResolver::SYSEXT_FOLDER, array(), $frameworkPackageKeys),
                );
 
-               $dependencyResolver = $this->getAccessibleMock('\TYPO3\CMS\Core\Package\DependencyResolver', array('getPackageKeysInBasePath'));
+               $dependencyResolver = $this->getAccessibleMock(DependencyResolver::class, array('getPackageKeysInBasePath'));
                $dependencyResolver->expects($this->any())->method('getPackageKeysInBasePath')->will($this->returnValueMap($basePathAssignment));
                $dependencyGraph = $dependencyResolver->_call('buildDependencyGraph', $unsortedPackageStatesConfiguration);
 
@@ -57,7 +57,7 @@ class DependencyResolverTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                        array($unsortedPackageStatesConfiguration, DependencyResolver::SYSEXT_FOLDER, array(), $frameworkPackageKeys),
                );
 
-               $dependencyResolver = $this->getAccessibleMock('\TYPO3\CMS\Core\Package\DependencyResolver', array('getPackageKeysInBasePath'));
+               $dependencyResolver = $this->getAccessibleMock(DependencyResolver::class, array('getPackageKeysInBasePath'));
                $dependencyResolver->expects($this->any())->method('getPackageKeysInBasePath')->will($this->returnValueMap($basePathAssignment));
                $sortedPackageStatesConfiguration = $dependencyResolver->_call('sortPackageStatesConfigurationByDependency', $unsortedPackageStatesConfiguration);
 
@@ -69,7 +69,7 @@ class DependencyResolverTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
         * @dataProvider buildDependencyGraphForPackagesBuildsCorrectGraphDataProvider
         */
        public function buildDependencyGraphForPackagesBuildsCorrectGraph($packages, $expectedGraph) {
-               $dependencyResolver = $this->getAccessibleMock('\TYPO3\CMS\Core\Package\DependencyResolver', array('dummy'));
+               $dependencyResolver = $this->getAccessibleMock(DependencyResolver::class, array('dummy'));
                $dependencyGraph = $dependencyResolver->_call('buildDependencyGraphForPackages', $packages, array_keys($packages));
 
                $this->assertEquals($expectedGraph, $dependencyGraph);
@@ -98,7 +98,7 @@ class DependencyResolverTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                        array($unsortedPackageStatesConfiguration, DependencyResolver::SYSEXT_FOLDER, array(), array()),
                );
 
-               $dependencyResolver = $this->getAccessibleMock('\TYPO3\CMS\Core\Package\DependencyResolver', array('getActivePackageKeysOfType'));
+               $dependencyResolver = $this->getAccessibleMock(DependencyResolver::class, array('getActivePackageKeysOfType'));
                $dependencyResolver->expects($this->any())->method('getActivePackageKeysOfType')->will($this->returnValueMap($basePathAssignment));
                $dependencyResolver->_call('sortPackageStatesConfigurationByDependency', $unsortedPackageStatesConfiguration);
        }
@@ -113,7 +113,7 @@ class DependencyResolverTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                                'dependencies' => array('B'),
                        )
                );
-               $dependencyResolver = $this->getAccessibleMock('\TYPO3\CMS\Core\Package\DependencyResolver', array('dummy'));
+               $dependencyResolver = $this->getAccessibleMock(DependencyResolver::class, array('dummy'));
                $dependencyResolver->_call('buildDependencyGraphForPackages', $packages, array_keys($packages));
        }
 
@@ -869,7 +869,7 @@ class DependencyResolverTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
         * @dataProvider findPathInGraphReturnsCorrectPathDataProvider
         */
        public function findPathInGraphReturnsCorrectPath(array $graph, $from, $to, array $expected) {
-               $dependencyResolver = $this->getAccessibleMock('\TYPO3\CMS\Core\Package\DependencyResolver', array('dummy'));
+               $dependencyResolver = $this->getAccessibleMock(DependencyResolver::class, array('dummy'));
                $path = $dependencyResolver->_call('findPathInGraph', $graph, $from, $to);
 
                $this->assertSame($expected, $path);
index 3500f7f..9d4fd0b 100644 (file)
@@ -124,7 +124,7 @@ class PackageManagerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                        'Doctrine.Common' => $mockCommonPackage
                );
 
-               $packageManager = $this->getAccessibleMock('\TYPO3\Flow\Package\PackageManager', array('dummy'));
+               $packageManager = $this->getAccessibleMock(\TYPO3\Flow\Package\PackageManager::class, array('dummy'));
                $packageManager->_set('packages', $packages);
                $dependencyArray = $packageManager->_call('getDependencyArrayForPackage', 'TYPO3.Flow');
 
@@ -459,7 +459,7 @@ class PackageManagerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                        )
                );
 
-               $packageManager = $this->getAccessibleMock('\TYPO3\Flow\Package\PackageManager', array('resolvePackageDependencies'));
+               $packageManager = $this->getAccessibleMock(\TYPO3\Flow\Package\PackageManager::class, array('resolvePackageDependencies'));
                $packageManager->_set('packageStatesConfiguration', $packageStatesConfiguration);
 
                $this->assertEquals($packageKey, $packageManager->_call('getPackageKeyFromComposerName', $composerName));
index 2e94887..89e51b7 100644 (file)
@@ -127,7 +127,7 @@ class FileExtensionFilterTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
         */
        public function extensionFilterIgnoresCaseInAllowedExtensionCheck($fileExtension, $allowedExtensions, $disallowedExtensions, $isAllowed) {
                /** @var \TYPO3\CMS\Core\Resource\Filter\FileExtensionFilter $filter */
-               $filter = $this->getAccessibleMock('\TYPO3\CMS\Core\Resource\Filter\FileExtensionFilter', array('dummy'));
+               $filter = $this->getAccessibleMock(\TYPO3\CMS\Core\Resource\Filter\FileExtensionFilter::class, array('dummy'));
                $filter->setAllowedFileExtensions($allowedExtensions);
                $filter->setDisallowedFileExtensions($disallowedExtensions);
                $result = $filter->_call('isAllowed', 'file.' . $fileExtension);
index 2325f51..d9605cf 100644 (file)
@@ -42,7 +42,7 @@ class TemplateServiceTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $GLOBALS['TYPO3_LOADED_EXT'] = array();
                $this->templateService = new \TYPO3\CMS\Core\TypoScript\TemplateService();
                $this->templateService->tt_track = FALSE;
-               $this->templateServiceMock = $this->getAccessibleMock('\\TYPO3\\CMS\\Core\\TypoScript\\TemplateService', array('dummy'));
+               $this->templateServiceMock = $this->getAccessibleMock(\TYPO3\CMS\Core\TypoScript\TemplateService::class, array('dummy'));
                $this->templateServiceMock->tt_track = FALSE;
        }
 
index 697c840..1700f35 100644 (file)
@@ -573,7 +573,7 @@ class ExtensionManagementUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
         * @dataProvider executePositionedStringInsertionTrimsCorrectCharactersDataProvider
         */
        public function executePositionedStringInsertionTrimsCorrectCharacters($string, $expectedResult) {
-               $extensionManagementUtility = $this->getAccessibleMock('\\TYPO3\\CMS\\Core\\Utility\\ExtensionManagementUtility', array('dummy'));
+               $extensionManagementUtility = $this->getAccessibleMock(\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::class, array('dummy'));
                $string = $extensionManagementUtility->_call('executePositionedStringInsertion', $string, '');
                $this->assertEquals($expectedResult, $string);
        }
index c983f71..9d450f8 100644 (file)
@@ -62,7 +62,7 @@ class ResourceUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $result = $unsortedList;
                usort(
                        $result,
-                       array('\\TYPO3\\CMS\\Core\\Utility\\ResourceUtility', 'recursiveFileListSortingHelper')
+                       array(\TYPO3\CMS\Core\Utility\ResourceUtility::class, 'recursiveFileListSortingHelper')
                );
 
                $this->assertEquals($expectedList, $result);
index 169c8f7..1b037b5 100644 (file)
@@ -309,8 +309,8 @@ class RootlineUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
         * @test
         */
        public function enrichWithRelationFieldsCreatesWhereClauseForDisabledField() {
-               $mockDatabaseConnection = $this->getMock('\TYPO3\CMS\Core\Database\DatabaseConnection', array('exec_SELECTgetRows'), array(), '', FALSE);
-               $subject = $this->getAccessibleMock('\TYPO3\CMS\Core\Utility\RootlineUtility', array('columnHasRelationToResolve'), array(1, '', $this->pageContextMock));
+               $mockDatabaseConnection = $this->getMock(\TYPO3\CMS\Core\Database\DatabaseConnection::class, array('exec_SELECTgetRows'), array(), '', FALSE);
+               $subject = $this->getAccessibleMock(\TYPO3\CMS\Core\Utility\RootlineUtility::class, array('columnHasRelationToResolve'), array(1, '', $this->pageContextMock));
                $subject->_set('databaseConnection', $mockDatabaseConnection);
                $GLOBALS['TYPO3_CONF_VARS']['FE']['pageOverlayFields'] = '';
                $foreign_table = uniqid('foreign_table');
index 4d30b11..69ff8ed 100644 (file)
@@ -30,7 +30,7 @@ class BlogRepository extends \TYPO3\CMS\Extbase\Persistence\Repository {
         */
        public function initializeObject() {
                /*
-               $querySettings = $this->objectManager->get('\TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings');
+               $querySettings = $this->objectManager->get(\TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::class);
                $querySettings->setRespectStoragePage(FALSE);
                $this->setDefaultQuerySettings($querySettings);
                 */
index 6c7b719..6885448 100644 (file)
@@ -198,7 +198,7 @@ class InTest extends \TYPO3\CMS\Core\Tests\FunctionalTestCase {
                $blog = $this->blogRepository->findByUid(1);
 
                $this->assertInstanceOf(
-                       '\TYPO3\CMS\Extbase\Persistence\Generic\LazyObjectStorage',
+                       \TYPO3\CMS\Extbase\Persistence\Generic\LazyObjectStorage::class,
                        $blog->getPosts()
                );
 
@@ -218,7 +218,7 @@ class InTest extends \TYPO3\CMS\Core\Tests\FunctionalTestCase {
                $blog = $this->blogRepository->findByUid(1);
 
                $this->assertInstanceOf(
-                       '\TYPO3\CMS\Extbase\Persistence\Generic\LazyObjectStorage',
+                       \TYPO3\CMS\Extbase\Persistence\Generic\LazyObjectStorage::class,
                        $blog->getPosts()
                );
 
index 88187b1..dca1bd3 100644 (file)
@@ -108,7 +108,7 @@ class AbstractControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $flashMessageQueue->expects($this->once())->method('enqueue')->with($this->equalTo($expectedMessage));
 
                $controllerContext = $this->getMock(
-                       '\\TYPO3\\CMS\\Extbase\\Mvc\\Controller\\ControllerContext',
+                       \TYPO3\CMS\Extbase\Mvc\Controller\ControllerContext::class,
                        array('getFlashMessageQueue')
                );
                $controllerContext->expects($this->once())->method('getFlashMessageQueue')->will($this->returnValue($flashMessageQueue));
index ab50bd7..4db97f2 100644 (file)
@@ -413,7 +413,7 @@ class DataMapFactoryTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
        public function classNameTableNameMappings() {
                return array(
                        'Core classes' => array(\TYPO3\CMS\Belog\Domain\Model\LogEntry::class, 'tx_belog_domain_model_logentry'),
-                       'Core classes with namespaces and leading backslash' => array('\\TYPO3\\CMS\\Belog\\Domain\\Model\\LogEntry', 'tx_belog_domain_model_logentry'),
+                       'Core classes with namespaces and leading backslash' => array(\TYPO3\CMS\Belog\Domain\Model\LogEntry::class, 'tx_belog_domain_model_logentry'),
                        'Extension classes' => array('ExtbaseTeam\\BlogExample\\Domain\\Model\\Blog', 'tx_blogexample_domain_model_blog'),
                        'Extension classes with namespaces and leading backslash' => array('\\ExtbaseTeam\\BlogExample\\Domain\\Model\\Blog', 'tx_blogexample_domain_model_blog'),
                        'Extension classes without namespace' => array('Tx_News_Domain_Model_News', 'tx_news_domain_model_news'),
index 5510fb9..924e643 100644 (file)
@@ -51,7 +51,7 @@ class FieldProviderTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
 
                /** @var \TYPO3\CMS\Extbase\Scheduler\FieldProvider|\PHPUnit_Framework_MockObject_MockObject|\Tx_Phpunit_Interface_AccessibleObject $fieldProvider */
                $fieldProvider = $this->getAccessibleMock(
-                       '\TYPO3\CMS\Extbase\Scheduler\FieldProvider',
+                       \TYPO3\CMS\Extbase\Scheduler\FieldProvider::class,
                        array('getActionLabel'),
                        array(),
                        '',
@@ -86,7 +86,7 @@ class FieldProviderTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
        public function validateAdditionalFieldsReturnsTrue() {
                /** @var \TYPO3\CMS\Extbase\Scheduler\FieldProvider|\PHPUnit_Framework_MockObject_MockObject|\Tx_Phpunit_Interface_AccessibleObject $fieldProvider */
                $fieldProvider = $this->getAccessibleMock(
-                       '\TYPO3\CMS\Extbase\Scheduler\FieldProvider',
+                       \TYPO3\CMS\Extbase\Scheduler\FieldProvider::class,
                        array('dummy'),
                        array(),
                        '',
@@ -133,7 +133,7 @@ class FieldProviderTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
 
                /** @var \TYPO3\CMS\Extbase\Scheduler\FieldProvider|\PHPUnit_Framework_MockObject_MockObject|\Tx_Phpunit_Interface_AccessibleObject $fieldProvider */
                $fieldProvider = $this->getAccessibleMock(
-                       '\TYPO3\CMS\Extbase\Scheduler\FieldProvider',
+                       \TYPO3\CMS\Extbase\Scheduler\FieldProvider::class,
                        array('getActionLabel', 'getArgumentLabel', 'getCommandControllerActionArgumentFields'),
                        array(),
                        '',
index 9c26d08..8b24bb9 100644 (file)
@@ -140,7 +140,7 @@ class CollectionValidatorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
         */
        public function collectionValidatorIsValidEarlyReturnsOnUnitializedLazyObjectStorages() {
                $parentObject  = new \TYPO3\CMS\Extbase\Tests\Fixture\Entity('Foo');
-               $elementType = '\TYPO3\CMS\Extbase\Tests\Fixture\Entity';
+               $elementType = \TYPO3\CMS\Extbase\Tests\Fixture\Entity::class;
                $lazyObjectStorage = new \TYPO3\CMS\Extbase\Persistence\Generic\LazyObjectStorage(
                        $parentObject,
                        'someProperty',
@@ -159,7 +159,7 @@ class CollectionValidatorTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
         */
        public function collectionValidatorCallsCollectionElementValidatorWhenValidatingObjectStorages() {
                $entity = new \TYPO3\CMS\Extbase\Tests\Fixture\Entity('Foo');
-               $elementType = '\TYPO3\CMS\Extbase\Tests\Fixture\Entity';
+               $elementType = \TYPO3\CMS\Extbase\Tests\Fixture\Entity::class;
                $objectStorage = new \TYPO3\CMS\Extbase\Persistence\ObjectStorage();
                $objectStorage->attach($entity);
                $aValidator = new \TYPO3\CMS\Extbase\Validation\Validator\GenericObjectValidator(array());
index df11467..ae01050 100644 (file)
@@ -169,7 +169,7 @@ class ValidatorResolverTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
        public function createValidatorThrowsNoSuchValidatorExceptionIfAValidatorCouldNotBeResolved() {
                $this->markTestSkipped('');
                $className = uniqid('Test');
-               $this->setExpectedException('\\TYPO3\\CMS\\Extbase\\Validation\\Exception\NoSuchValidatorException', '', 1365799920);
+               $this->setExpectedException(\TYPO3\CMS\Extbase\Validation\Exception\NoSuchValidatorException::class, '', 1365799920);
                $this->validatorResolver->createValidator($className);
        }
 
index 0b069ea..345eda8 100644 (file)
@@ -33,7 +33,7 @@ class DownloadControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $dummyExtension = $this->getMock(\TYPO3\CMS\Extensionmanager\Domain\Model\Extension::class);
                $dummyExtension->expects($this->any())->method('getExtensionKey')->will($this->returnValue($dummyExtensionName));
 
-               $downloadUtilityMock = $this->getMock('\\TYPO3\\CMS\\Extensionmanager\\Utility\\DownloadUtility');
+               $downloadUtilityMock = $this->getMock(\TYPO3\CMS\Extensionmanager\Utility\DownloadUtility::class);
                $downloadUtilityMock->expects($this->any())->method('setDownloadPath')->willThrowException($dummyException);
 
                $subject = $this->getAccessibleMock(\TYPO3\CMS\Extensionmanager\Controller\DownloadController::class, array('dummy'));
index 62a9b88..ff50d6f 100644 (file)
@@ -316,7 +316,7 @@ class InstallUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $absPath = PATH_site . $this->fakedExtensions[$extKey]['siteRelPath'];
                \TYPO3\CMS\Core\Utility\GeneralUtility::mkdir($absPath . 'Initialisation');
                file_put_contents($absPath . 'Initialisation/' . $fileName, 'DUMMY');
-               $registryMock = $this->getMock('\\TYPO3\\CMS\\Core\\Registry', array('get', 'set'));
+               $registryMock = $this->getMock(\TYPO3\CMS\Core\Registry::class, array('get', 'set'));
                $registryMock
                        ->expects($this->any())
                        ->method('get')
index 53b73e2..5a9dbab 100644 (file)
@@ -114,7 +114,7 @@ class CategoryMenuUtility {
                                uasort(
                                        $pages,
                                        array(
-                                               '\TYPO3\CMS\Frontend\ContentObject\Menu\CategoryMenuUtility',
+                                               \TYPO3\CMS\Frontend\ContentObject\Menu\CategoryMenuUtility::class,
                                                'sortPagesUtility'
                                        )
                                );
index 2de436a..09031a7 100644 (file)
@@ -1425,7 +1425,7 @@ class ContentObjectRendererTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                                )
                        ),
                );
-               $this->subject = $this->getAccessibleMock('\\TYPO3\\CMS\\Frontend\\ContentObject\\ContentObjectRenderer', array('getTreeList'));
+               $this->subject = $this->getAccessibleMock(\TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::class, array('getTreeList'));
                $this->subject->start(array(), 'tt_content');
                $conf = array(
                        'recursive' => '15',
@@ -1462,7 +1462,7 @@ class ContentObjectRendererTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                                )
                        ),
                );
-               $this->subject = $this->getAccessibleMock('\\TYPO3\\CMS\\Frontend\\ContentObject\\ContentObjectRenderer', array('getTreeList'));
+               $this->subject = $this->getAccessibleMock(\TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::class, array('getTreeList'));
                $GLOBALS['TSFE']->id = 27;
                $this->subject->start(array(), 'tt_content');
                $conf = array(
index 98e66e6..76a4316 100644 (file)
@@ -26,7 +26,7 @@ class TypoScriptFrontendControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCas
        protected $fixture;
 
        public function setUp() {
-               $this->fixture = $this->getAccessibleMock('\\TYPO3\\CMS\\Frontend\\Controller\\TypoScriptFrontendController', array('dummy'), array(), '', FALSE);
+               $this->fixture = $this->getAccessibleMock(\TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::class, array('dummy'), array(), '', FALSE);
                $this->fixture->TYPO3_CONF_VARS = $GLOBALS['TYPO3_CONF_VARS'];
                $this->fixture->TYPO3_CONF_VARS['SYS']['encryptionKey'] = '170928423746123078941623042360abceb12341234231';
        }
@@ -131,4 +131,4 @@ class TypoScriptFrontendControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCas
                $refValue = $this->fixture->_callRef('roundTripCryptString', $clearText);
                $this->assertEquals($clearText, $this->fixture->_callRef('roundTripCryptString', $refValue));
        }
-}
\ No newline at end of file
+}
index 751028e..7a59477 100644 (file)
@@ -29,7 +29,7 @@ class MediaWizardProviderTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
         * Setup
         */
        public function setUp() {
-               $this->fixture = $this->getAccessibleMock('\\TYPO3\\CMS\\Frontend\\MediaWizard\\MediaWizardProvider', array('dummy'), array(), '', FALSE);
+               $this->fixture = $this->getAccessibleMock(\TYPO3\CMS\Frontend\MediaWizard\MediaWizardProvider::class, array('dummy'), array(), '', FALSE);
        }
 
        /**
index 9639ef5..d2e46ac 100644 (file)
@@ -151,7 +151,7 @@ class DirectoryNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\WarningStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\WarningStatus::class, $status);
        }
 
        /**
@@ -177,7 +177,7 @@ class DirectoryNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\ErrorStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\ErrorStatus::class, $status);
        }
 
        /**
@@ -203,7 +203,7 @@ class DirectoryNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\ErrorStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\ErrorStatus::class, $status);
        }
 
        /**
@@ -229,7 +229,7 @@ class DirectoryNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\NoticeStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\NoticeStatus::class, $status);
        }
 
        /**
@@ -255,7 +255,7 @@ class DirectoryNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\OkStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\OkStatus::class, $status);
        }
 
        /**
@@ -305,8 +305,8 @@ class DirectoryNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $status = $node->getStatus();
                $statusOfDirectory = $status[0];
                $statusOfChild = $status[1];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\OkStatus', $statusOfDirectory);
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\ErrorStatus', $statusOfChild);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\OkStatus::class, $statusOfDirectory);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\ErrorStatus::class, $statusOfChild);
        }
 
        /**
index 85b657d..1e8a284 100644 (file)
@@ -210,7 +210,7 @@ class FileNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\WarningStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\WarningStatus::class, $status);
        }
 
        /**
@@ -237,7 +237,7 @@ class FileNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\ErrorStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\ErrorStatus::class, $status);
        }
 
        /**
@@ -264,7 +264,7 @@ class FileNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\NoticeStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\NoticeStatus::class, $status);
        }
 
        /**
@@ -291,7 +291,7 @@ class FileNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\NoticeStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\NoticeStatus::class, $status);
        }
 
        /**
@@ -318,7 +318,7 @@ class FileNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\NoticeStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\NoticeStatus::class, $status);
        }
 
        /**
@@ -345,7 +345,7 @@ class FileNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\OkStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\OkStatus::class, $status);
        }
 
        /**
index c817154..f8f94f2 100644 (file)
@@ -159,7 +159,7 @@ class LinkNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\WarningStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\WarningStatus::class, $status);
        }
 
        /**
@@ -182,7 +182,7 @@ class LinkNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\ErrorStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\ErrorStatus::class, $status);
        }
 
        /**
@@ -204,7 +204,7 @@ class LinkNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\OkStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\OkStatus::class, $status);
        }
 
        /**
index 5fa077c..e31eeed 100644 (file)
@@ -185,7 +185,7 @@ class RootNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                $statusArray = $node->getStatus();
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $status = $statusArray[0];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\OkStatus', $status);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\OkStatus::class, $status);
        }
 
        /**
@@ -214,8 +214,8 @@ class RootNodeTest extends \TYPO3\CMS\Core\Tests\UnitTestCase {
                /** @var $status \TYPO3\CMS\Install\Status\StatusInterface */
                $statusSelf = $statusArray[0];
                $statusOfChild = $statusArray[1];
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\OkStatus', $statusSelf);
-               $this->assertInstanceOf('\TYPO3\CMS\Install\Status\ErrorStatus', $statusOfChild);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\OkStatus::class, $statusSelf);
+               $this->assertInstanceOf(\TYPO3\CMS\Install\Status\ErrorStatus::class, $statusOfChild);
        }
 
        /**