From 6190776d6adcfef0bdc18f424262d1be297e1bda Mon Sep 17 00:00:00 2001 From: Stefan Neufeind <typo3.neufeind@speedpartner.de> Date: Mon, 1 Dec 2014 14:06:03 +0100 Subject: [PATCH] [TASK] Use name-resolution instead of strings where possible: 11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (part for EXT:backend) 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. Change-Id: I49f47b7fb3dbee281af8e166afc3c36662730b54 Resolves: #63477 Releases: master Reviewed-on: http://review.typo3.org/34867 Reviewed-by: Frank Nägler <typo3@naegler.net> Tested-by: Frank Nägler <typo3@naegler.net> Reviewed-by: Markus Klein <klein.t3@reelworx.at> Tested-by: Markus Klein <klein.t3@reelworx.at> --- .../ToolbarItems/ClearCacheToolbarItem.php | 2 +- .../ContentElement/MoveElementController.php | 2 +- .../NewContentElementController.php | 4 ++-- .../Classes/Controller/LoginController.php | 2 +- .../Controller/PageLayoutController.php | 4 ++-- .../Classes/Form/Element/InlineElement.php | 2 +- .../Classes/Form/Element/SuggestElement.php | 2 +- .../backend/Classes/Form/FormEngine.php | 6 ++--- .../Classes/Module/AbstractFunctionModule.php | 4 ++-- .../backend/Classes/Module/ModuleSettings.php | 10 ++++---- .../backend/Classes/Sprite/SpriteManager.php | 2 +- .../Classes/Template/DocumentTemplate.php | 2 +- .../Classes/Tree/View/PagePositionMap.php | 4 ++-- .../Classes/Utility/BackendUtility.php | 8 +++---- .../backend/Classes/Utility/IconUtility.php | 6 ++--- .../BackendLayout/DataProviderCollection.php | 2 +- .../Classes/View/BackendLayoutView.php | 2 +- .../backend/Classes/View/PageLayoutView.php | 4 ++-- .../ConditionMatcherTest.php | 12 +++++----- .../Controller/File/FileControllerTest.php | 24 +++++++++---------- .../Unit/Form/Element/InlineElementTest.php | 2 +- .../Unit/Form/ElementConditionMatcherTest.php | 8 +++---- .../Tests/Unit/Form/FormEngineTest.php | 2 +- .../Unit/Module/ModuleControllerTest.php | 6 ++--- .../Unit/Tree/Pagetree/DataProviderTest.php | 2 +- .../Unit/Tree/TreeNodeCollectionTest.php | 12 +++++----- .../Tests/Unit/Utility/BackendUtilityTest.php | 24 +++++++++---------- .../Tests/Unit/Utility/IconUtilityTest.php | 8 +++---- .../BackendLayoutCollectionTest.php | 8 +++---- .../DataProviderCollectionTest.php | 8 +++---- .../Tests/Unit/View/BackendLayoutViewTest.php | 2 +- .../Tests/Unit/View/ModuleMenuViewTest.php | 4 ++-- typo3/sysext/backend/ext_localconf.php | 16 ++++++------- 33 files changed, 103 insertions(+), 103 deletions(-) diff --git a/typo3/sysext/backend/Classes/Backend/ToolbarItems/ClearCacheToolbarItem.php b/typo3/sysext/backend/Classes/Backend/ToolbarItems/ClearCacheToolbarItem.php index eb2792e4c722..dc6b878f9272 100644 --- a/typo3/sysext/backend/Classes/Backend/ToolbarItems/ClearCacheToolbarItem.php +++ b/typo3/sysext/backend/Classes/Backend/ToolbarItems/ClearCacheToolbarItem.php @@ -93,7 +93,7 @@ class ClearCacheToolbarItem implements ToolbarItemInterface { foreach ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['additionalBackendItems']['cacheActions'] as $cacheAction) { $hookObject = GeneralUtility::getUserObj($cacheAction); if (!$hookObject instanceof ClearCacheActionsHookInterface) { - throw new \UnexpectedValueException('$hookObject must implement interface TYPO3\\CMS\\Backend\\Toolbar\\ClearCacheActionsHookInterface', 1228262000); + throw new \UnexpectedValueException('$hookObject must implement interface ' . \TYPO3\CMS\Backend\Toolbar\ClearCacheActionsHookInterface::class, 1228262000); } $hookObject->manipulateCacheActions($this->cacheActions, $this->optionValues); } diff --git a/typo3/sysext/backend/Classes/Controller/ContentElement/MoveElementController.php b/typo3/sysext/backend/Classes/Controller/ContentElement/MoveElementController.php index 1b1577132082..d3dac25f6fb7 100644 --- a/typo3/sysext/backend/Classes/Controller/ContentElement/MoveElementController.php +++ b/typo3/sysext/backend/Classes/Controller/ContentElement/MoveElementController.php @@ -182,7 +182,7 @@ class MoveElementController { // Load SHARED page-TSconfig settings and retrieve column list from there, if applicable: // SHARED page-TSconfig settings. $modTSconfig_SHARED = BackendUtility::getModTSconfig($this->page_id, 'mod.SHARED'); - $colPosArray = GeneralUtility::callUserFunction('TYPO3\\CMS\\Backend\\View\\BackendLayoutView->getColPosListItemsParsed', $this->page_id, $this); + $colPosArray = GeneralUtility::callUserFunction(\TYPO3\CMS\Backend\View\BackendLayoutView::class . '->getColPosListItemsParsed', $this->page_id, $this); $colPosIds = array(); foreach ($colPosArray as $colPos) { $colPosIds[] = $colPos[1]; diff --git a/typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php b/typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php index d0b07b74528f..fce0cc924061 100644 --- a/typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php +++ b/typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php @@ -176,7 +176,7 @@ class NewContentElementController { foreach ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['cms']['db_new_content_el']['wizardItemsHook'] as $classData) { $hookObject = GeneralUtility::getUserObj($classData); if (!$hookObject instanceof \TYPO3\CMS\Backend\Wizard\NewContentElementWizardHookInterface) { - throw new \UnexpectedValueException('$hookObject must implement interface TYPO3\\CMS\\Backend\\Wizard\\NewContentElementWizardHookInterface', 1227834741); + throw new \UnexpectedValueException('$hookObject must implement interface ' . \TYPO3\CMS\Backend\Wizard\NewContentElementWizardHookInterface::class, 1227834741); } $hookObject->manipulateWizardItems($wizardItems, $this); } @@ -264,7 +264,7 @@ class NewContentElementController { $code = $GLOBALS['LANG']->getLL('sel2', 1) . '<br /><br />'; // Load SHARED page-TSconfig settings and retrieve column list from there, if applicable: - $colPosArray = GeneralUtility::callUserFunction('TYPO3\\CMS\\Backend\\View\\BackendLayoutView->getColPosListItemsParsed', $this->id, $this); + $colPosArray = GeneralUtility::callUserFunction(\TYPO3\CMS\Backend\View\BackendLayoutView::class . '->getColPosListItemsParsed', $this->id, $this); $colPosIds = array_column($colPosArray, 1); // Removing duplicates, if any $colPosList = implode(',', array_unique(array_map('intval', $colPosIds))); diff --git a/typo3/sysext/backend/Classes/Controller/LoginController.php b/typo3/sysext/backend/Classes/Controller/LoginController.php index fd012762e74a..d86a896a4494 100644 --- a/typo3/sysext/backend/Classes/Controller/LoginController.php +++ b/typo3/sysext/backend/Classes/Controller/LoginController.php @@ -617,7 +617,7 @@ class LoginController { * @return array Modified markers array */ protected function emitRenderLoginFormSignal(array $markers) { - $signalArguments = $this->getSignalSlotDispatcher()->dispatch('TYPO3\\CMS\\Backend\\Controller\\LoginController', self::SIGNAL_RenderLoginForm, array($this, $markers)); + $signalArguments = $this->getSignalSlotDispatcher()->dispatch(\TYPO3\CMS\Backend\Controller\LoginController::class, self::SIGNAL_RenderLoginForm, array($this, $markers)); return $signalArguments[1]; } diff --git a/typo3/sysext/backend/Classes/Controller/PageLayoutController.php b/typo3/sysext/backend/Classes/Controller/PageLayoutController.php index 8eadcd1cc5f3..5c49e83ed736 100644 --- a/typo3/sysext/backend/Classes/Controller/PageLayoutController.php +++ b/typo3/sysext/backend/Classes/Controller/PageLayoutController.php @@ -556,7 +556,7 @@ class PageLayoutController { $this->topFuncMenu = BackendUtility::getFuncMenu($this->id, 'SET[function]', $this->MOD_SETTINGS['function'], $this->MOD_MENU['function'], 'db_layout.php', ''); $this->languageMenu = count($this->MOD_MENU['language']) > 1 ? $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_general.xlf:LGL.language', TRUE) . BackendUtility::getFuncMenu($this->id, 'SET[language]', $this->current_sys_language, $this->MOD_MENU['language'], 'db_layout.php', '') : ''; // Find backend layout / coumns - $backendLayout = GeneralUtility::callUserFunction('TYPO3\\CMS\\Backend\\View\\BackendLayoutView->getSelectedBackendLayout', $this->id, $this); + $backendLayout = GeneralUtility::callUserFunction(\TYPO3\CMS\Backend\View\BackendLayoutView::class . '->getSelectedBackendLayout', $this->id, $this); if (count($backendLayout['__colPosList'])) { $this->colPosList = implode(',', $backendLayout['__colPosList']); } @@ -964,7 +964,7 @@ class PageLayoutController { // Setting up the tt_content columns to show: if (is_array($GLOBALS['TCA']['tt_content']['columns']['colPos']['config']['items'])) { $colList = array(); - $tcaItems = GeneralUtility::callUserFunction('TYPO3\\CMS\\Backend\\View\\BackendLayoutView->getColPosListItemsParsed', $this->id, $this); + $tcaItems = GeneralUtility::callUserFunction(\TYPO3\CMS\Backend\View\BackendLayoutView::class . '->getColPosListItemsParsed', $this->id, $this); foreach ($tcaItems as $temp) { $colList[] = $temp[1]; } diff --git a/typo3/sysext/backend/Classes/Form/Element/InlineElement.php b/typo3/sysext/backend/Classes/Form/Element/InlineElement.php index a605806de1ff..84b11e6f782c 100644 --- a/typo3/sysext/backend/Classes/Form/Element/InlineElement.php +++ b/typo3/sysext/backend/Classes/Form/Element/InlineElement.php @@ -150,7 +150,7 @@ class InlineElement { foreach ($tceformsInlineHook as $classData) { $processObject = GeneralUtility::getUserObj($classData); if (!$processObject instanceof \TYPO3\CMS\Backend\Form\Element\InlineElementHookInterface) { - throw new \UnexpectedValueException('$processObject must implement interface TYPO3\\CMS\\Backend\\Form\\Element\\InlineElementHookInterface', 1202072000); + throw new \UnexpectedValueException('$processObject must implement interface ' . \TYPO3\CMS\Backend\Form\Element\InlineElementHookInterface::class, 1202072000); } $processObject->init($this); $this->hookObjects[] = $processObject; diff --git a/typo3/sysext/backend/Classes/Form/Element/SuggestElement.php b/typo3/sysext/backend/Classes/Form/Element/SuggestElement.php index 903cf16227fa..34c54d740e07 100644 --- a/typo3/sysext/backend/Classes/Form/Element/SuggestElement.php +++ b/typo3/sysext/backend/Classes/Form/Element/SuggestElement.php @@ -273,7 +273,7 @@ class SuggestElement { // instantiate the class that should fetch the records for this $queryTable $receiverClassName = $config['receiverClass']; if (!class_exists($receiverClassName)) { - $receiverClassName = 'TYPO3\\CMS\\Backend\\Form\\Element\\SuggestDefaultReceiver'; + $receiverClassName = \TYPO3\CMS\Backend\Form\Element\SuggestDefaultReceiver::class; } $receiverObj = GeneralUtility::makeInstance($receiverClassName, $queryTable, $config); $params = array('value' => $search); diff --git a/typo3/sysext/backend/Classes/Form/FormEngine.php b/typo3/sysext/backend/Classes/Form/FormEngine.php index cfe5e296f8ca..bf34f62c3738 100644 --- a/typo3/sysext/backend/Classes/Form/FormEngine.php +++ b/typo3/sysext/backend/Classes/Form/FormEngine.php @@ -662,11 +662,11 @@ class FormEngine { 'inline' => array('appearance', 'behaviour', 'foreign_label', 'foreign_selector', 'foreign_unique', 'maxitems', 'minitems', 'size', 'autoSizeMax', 'symmetric_label', 'readOnly') ); // Create instance of InlineElement only if this a non-IRRE-AJAX call: - if (!isset($GLOBALS['ajaxID']) || strpos($GLOBALS['ajaxID'], 'TYPO3\\CMS\\Backend\\Form\\Element\\InlineElement::') !== 0) { + if (!isset($GLOBALS['ajaxID']) || strpos($GLOBALS['ajaxID'], \TYPO3\CMS\Backend\Form\Element\InlineElement::class . '::') !== 0) { $this->inline = GeneralUtility::makeInstance(\TYPO3\CMS\Backend\Form\Element\InlineElement::class); } // Create instance of \TYPO3\CMS\Backend\Form\Element\SuggestElement only if this a non-Suggest-AJAX call: - if (!isset($GLOBALS['ajaxID']) || strpos($GLOBALS['ajaxID'], 'TYPO3\\CMS\\Backend\\Form\\Element\\SuggestElement::') !== 0) { + if (!isset($GLOBALS['ajaxID']) || strpos($GLOBALS['ajaxID'], \TYPO3\CMS\Backend\Form\Element\SuggestElement::class . '::') !== 0) { $this->suggest = GeneralUtility::makeInstance(\TYPO3\CMS\Backend\Form\Element\SuggestElement::class); } // Prepare user defined objects (if any) for hooks which extend this function: @@ -2408,7 +2408,7 @@ class FormEngine { foreach ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tceforms.php']['dbFileIcons'] as $classRef) { $hookObject = GeneralUtility::getUserObj($classRef); if (!$hookObject instanceof DatabaseFileIconsHookInterface) { - throw new \UnexpectedValueException('$hookObject must implement interface TYPO3\\CMS\\Backend\\Form\\DatabaseFileIconsHookInterface', 1290167704); + throw new \UnexpectedValueException('$hookObject must implement interface ' . \TYPO3\CMS\Backend\Form\DatabaseFileIconsHookInterface::class, 1290167704); } $additionalParams = array( 'mode' => $mode, diff --git a/typo3/sysext/backend/Classes/Module/AbstractFunctionModule.php b/typo3/sysext/backend/Classes/Module/AbstractFunctionModule.php index f091e0e22ad6..0562498b31a8 100644 --- a/typo3/sysext/backend/Classes/Module/AbstractFunctionModule.php +++ b/typo3/sysext/backend/Classes/Module/AbstractFunctionModule.php @@ -46,7 +46,7 @@ use TYPO3\CMS\Core\Utility\GeneralUtility; * * \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::insertModuleFunction( * 'web_info', - * 'TYPO3\\CMS\\Frontend\\Controller\\PageInformationController', + * \TYPO3\CMS\Frontend\Controller\PageInformationController::class, * NULL, * 'LLL:EXT:cms/locallang_tca.xlf:mod_tx_cms_webinfo_page' * ); @@ -61,7 +61,7 @@ use TYPO3\CMS\Core\Utility\GeneralUtility; * * \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::insertModuleFunction( * 'web_func', - * 'TYPO3\\CMS\\WizardCrpages\\Controller\\CreatePagesWizardModuleFunctionController', + * \TYPO3\CMS\WizardCrpages\Controller\CreatePagesWizardModuleFunctionController::class * NULL, * 'LLL:EXT:wizard_crpages/locallang.xlf:wiz_crMany', * 'wiz' diff --git a/typo3/sysext/backend/Classes/Module/ModuleSettings.php b/typo3/sysext/backend/Classes/Module/ModuleSettings.php index a2a863258b03..eb647f6459a2 100644 --- a/typo3/sysext/backend/Classes/Module/ModuleSettings.php +++ b/typo3/sysext/backend/Classes/Module/ModuleSettings.php @@ -160,7 +160,7 @@ class ModuleSettings { public function setStoreList($storeList) { $this->storeList = is_array($storeList) ? $storeList : GeneralUtility::trimExplode(',', $storeList, TRUE); if ($this->writeDevLog) { - GeneralUtility::devLog('Store list:' . implode(',', $this->storeList), 'TYPO3\\CMS\\Backend\\ModuleSettings', 0); + GeneralUtility::devLog('Store list:' . implode(',', $this->storeList), \TYPO3\CMS\Backend\ModuleSettings::class, 0); } } @@ -174,7 +174,7 @@ class ModuleSettings { $storeList = is_array($storeList) ? $storeList : GeneralUtility::trimExplode(',', $storeList, TRUE); $this->storeList = array_merge($this->storeList, $storeList); if ($this->writeDevLog) { - GeneralUtility::devLog('Store list:' . implode(',', $this->storeList), 'TYPO3\\CMS\\Backend\\ModuleSettings', 0); + GeneralUtility::devLog('Store list:' . implode(',', $this->storeList), \TYPO3\CMS\Backend\ModuleSettings::class, 0); } } @@ -194,7 +194,7 @@ class ModuleSettings { } unset($this->storeList[$this->prefix . '_storedSettings']); if ($this->writeDevLog) { - GeneralUtility::devLog('Store list:' . implode(',', $this->storeList), 'TYPO3\\CMS\\Backend\\ModuleSettings', 0); + GeneralUtility::devLog('Store list:' . implode(',', $this->storeList), \TYPO3\CMS\Backend\ModuleSettings::class, 0); } } @@ -290,7 +290,7 @@ class ModuleSettings { $writeArray = array(); if (is_array($storeControl)) { if ($this->writeDevLog) { - GeneralUtility::devLog('Store command: ' . GeneralUtility::arrayToLogString($storeControl), 'TYPO3\\CMS\\Backend\\ModuleSettings', 0); + GeneralUtility::devLog('Store command: ' . GeneralUtility::arrayToLogString($storeControl), \TYPO3\CMS\Backend\ModuleSettings::class, 0); } // Processing LOAD if ($storeControl['LOAD'] and $storeIndex) { @@ -340,7 +340,7 @@ class ModuleSettings { $writeArray[$this->prefix . '_storedSettings'] = serialize($this->storedSettings); $GLOBALS['SOBE']->MOD_SETTINGS = \TYPO3\CMS\Backend\Utility\BackendUtility::getModuleData($GLOBALS['SOBE']->MOD_MENU, $writeArray, $mconfName ? $mconfName : $GLOBALS['SOBE']->MCONF['name'], $this->type); if ($this->writeDevLog) { - GeneralUtility::devLog('Settings stored:' . $this->msg, 'TYPO3\\CMS\\Backend\\ModuleSettings', 0); + GeneralUtility::devLog('Settings stored:' . $this->msg, \TYPO3\CMS\Backend\ModuleSettings::class, 0); } } diff --git a/typo3/sysext/backend/Classes/Sprite/SpriteManager.php b/typo3/sysext/backend/Classes/Sprite/SpriteManager.php index 970567fb0e3f..9be1801f9035 100644 --- a/typo3/sysext/backend/Classes/Sprite/SpriteManager.php +++ b/typo3/sysext/backend/Classes/Sprite/SpriteManager.php @@ -83,7 +83,7 @@ class SpriteManager { $handler = GeneralUtility::makeInstance($handlerClass); // Throw exception if handler class does not implement required interface if (!$handler instanceof \TYPO3\CMS\Backend\Sprite\SpriteIconGeneratorInterface) { - throw new \RuntimeException('Class ' . $handlerClass . ' in $TYPO3_CONF_VARS[BE][spriteIconGenerator_handler] ' . ' does not implement TYPO3\\CMS\\Backend\\Sprite\\SpriteIconGeneratorInterface', 1294586333); + throw new \RuntimeException('Class ' . $handlerClass . ' in $TYPO3_CONF_VARS[BE][spriteIconGenerator_handler] ' . ' does not implement ' . \TYPO3\CMS\Backend\Sprite\SpriteIconGeneratorInterface::class, 1294586333); } // Create temp directory if missing if (!is_dir((PATH_site . self::$tempPath))) { diff --git a/typo3/sysext/backend/Classes/Template/DocumentTemplate.php b/typo3/sysext/backend/Classes/Template/DocumentTemplate.php index a02a43bf5c02..93f124d57645 100644 --- a/typo3/sysext/backend/Classes/Template/DocumentTemplate.php +++ b/typo3/sysext/backend/Classes/Template/DocumentTemplate.php @@ -911,7 +911,7 @@ function jumpToUrl(URL) { // Logging: Can't find better place to put it: if (TYPO3_DLOG) { - GeneralUtility::devLog('END of BACKEND session', 'TYPO3\\CMS\\Backend\\Template\\DocumentTemplate', 0, array('_FLUSH' => TRUE)); + GeneralUtility::devLog('END of BACKEND session', \TYPO3\CMS\Backend\Template\DocumentTemplate::class, 0, array('_FLUSH' => TRUE)); } return $str; } diff --git a/typo3/sysext/backend/Classes/Tree/View/PagePositionMap.php b/typo3/sysext/backend/Classes/Tree/View/PagePositionMap.php index f938a857765e..16da726d3740 100644 --- a/typo3/sysext/backend/Classes/Tree/View/PagePositionMap.php +++ b/typo3/sysext/backend/Classes/Tree/View/PagePositionMap.php @@ -393,7 +393,7 @@ class PagePositionMap { $row1 = ''; $row2 = ''; $count = \TYPO3\CMS\Core\Utility\MathUtility::forceIntegerInRange(count($colPosArray), 1); - $backendLayout = GeneralUtility::callUserFunction('TYPO3\\CMS\\Backend\\View\\BackendLayoutView->getSelectedBackendLayout', $pid, $this); + $backendLayout = GeneralUtility::callUserFunction(\TYPO3\CMS\Backend\View\BackendLayoutView::class . '->getSelectedBackendLayout', $pid, $this); if (isset($backendLayout['__config']['backend_layout.'])) { $table = '<div class="t3-gridContainer"><table border="0" cellspacing="0" cellpadding="0" id="typo3-ttContentList">'; $colCount = (int)$backendLayout['__config']['backend_layout.']['colCount']; @@ -403,7 +403,7 @@ class PagePositionMap { $table .= '<col style="width:' . 100 / $colCount . '%"></col>'; } $table .= '</colgroup>'; - $tcaItems = GeneralUtility::callUserFunction('TYPO3\\CMS\\Backend\\View\\BackendLayoutView->getColPosListItemsParsed', $pid, $this); + $tcaItems = GeneralUtility::callUserFunction(\TYPO3\CMS\Backend\View\BackendLayoutView::class . '->getColPosListItemsParsed', $pid, $this); // Cycle through rows for ($row = 1; $row <= $rowCount; $row++) { $rowConfig = $backendLayout['__config']['backend_layout.']['rows.'][$row . '.']; diff --git a/typo3/sysext/backend/Classes/Utility/BackendUtility.php b/typo3/sysext/backend/Classes/Utility/BackendUtility.php index c4094dd8ce87..49f474c07681 100644 --- a/typo3/sysext/backend/Classes/Utility/BackendUtility.php +++ b/typo3/sysext/backend/Classes/Utility/BackendUtility.php @@ -529,7 +529,7 @@ class BackendUtility { } // Sort fields by the translated value if (count($excludeArrayTable) > 0) { - usort($excludeArrayTable, array('TYPO3\\CMS\\Backend\\Form\\FlexFormsHelper', 'compareArraysByFirstValue')); + usort($excludeArrayTable, array(\TYPO3\CMS\Backend\Form\FlexFormsHelper::class, 'compareArraysByFirstValue')); $finalExcludeArray = array_merge($finalExcludeArray, $excludeArrayTable); } } @@ -2941,7 +2941,7 @@ class BackendUtility { */ static public function setUpdateSignal($set = '', $params = '') { $beUser = static::getBackendUserAuthentication(); - $modData = $beUser->getModuleData('TYPO3\\CMS\\Backend\\Utility\\BackendUtility::getUpdateSignal', 'ses'); + $modData = $beUser->getModuleData(\TYPO3\CMS\Backend\Utility\BackendUtility::class . '::getUpdateSignal', 'ses'); if ($set) { $modData[$set] = array( 'set' => $set, @@ -2951,7 +2951,7 @@ class BackendUtility { // clear the module data $modData = array(); } - $beUser->pushModuleData('TYPO3\\CMS\\Backend\\Utility\\BackendUtility::getUpdateSignal', $modData); + $beUser->pushModuleData(\TYPO3\CMS\Backend\Utility\BackendUtility::class . '::getUpdateSignal', $modData); } /** @@ -2964,7 +2964,7 @@ class BackendUtility { */ static public function getUpdateSignalCode() { $signals = array(); - $modData = static::getBackendUserAuthentication()->getModuleData('TYPO3\\CMS\\Backend\\Utility\\BackendUtility::getUpdateSignal', 'ses'); + $modData = static::getBackendUserAuthentication()->getModuleData(\TYPO3\CMS\Backend\Utility\BackendUtility::class . '::getUpdateSignal', 'ses'); if (!count($modData)) { return ''; } diff --git a/typo3/sysext/backend/Classes/Utility/IconUtility.php b/typo3/sysext/backend/Classes/Utility/IconUtility.php index 8ca604352f74..df52dbfe19ef 100644 --- a/typo3/sysext/backend/Classes/Utility/IconUtility.php +++ b/typo3/sysext/backend/Classes/Utility/IconUtility.php @@ -786,7 +786,7 @@ class IconUtility { foreach ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_iconworks.php']['overrideResourceIcon'] as $classRef) { $hookObject = GeneralUtility::getUserObj($classRef); if (!$hookObject instanceof IconUtilityOverrideResourceIconHookInterface) { - throw new \UnexpectedValueException('$hookObject must implement interface TYPO3\\CMS\\Backend\\Utility\\IconUtilityOverrideResourceIconHookInterface', 1393574895); + throw new \UnexpectedValueException('$hookObject must implement interface ' . \TYPO3\CMS\Backend\Utility\IconUtilityOverrideResourceIconHookInterface::class, 1393574895); } $hookObject->overrideResourceIcon($resource, $iconName, $options, $overlays); } @@ -1051,7 +1051,7 @@ class IconUtility { * @return array */ static protected function emitBuildSpriteHtmlIconTagSignal(array $tagAttributes, $innerHtml, $tagName) { - return static::getSignalSlotDispatcher()->dispatch('TYPO3\\CMS\\Backend\\Utility\\IconUtility', 'buildSpriteHtmlIconTag', array($tagAttributes, $innerHtml, $tagName)); + return static::getSignalSlotDispatcher()->dispatch(\TYPO3\CMS\Backend\Utility\IconUtility::class, 'buildSpriteHtmlIconTag', array($tagAttributes, $innerHtml, $tagName)); } /** @@ -1062,7 +1062,7 @@ class IconUtility { * @param string $cssClasses the CSS classes to be used as a string */ static protected function emitBuildSpriteIconClassesSignal($iconName, &$cssClasses) { - static::getSignalSlotDispatcher()->dispatch('TYPO3\\CMS\\Backend\\Utility\\IconUtility', 'buildSpriteIconClasses', array($iconName, &$cssClasses)); + static::getSignalSlotDispatcher()->dispatch(\TYPO3\CMS\Backend\Utility\IconUtility::class, 'buildSpriteIconClasses', array($iconName, &$cssClasses)); } /** diff --git a/typo3/sysext/backend/Classes/View/BackendLayout/DataProviderCollection.php b/typo3/sysext/backend/Classes/View/BackendLayout/DataProviderCollection.php index 63bab53ed3ec..117cfb65870a 100644 --- a/typo3/sysext/backend/Classes/View/BackendLayout/DataProviderCollection.php +++ b/typo3/sysext/backend/Classes/View/BackendLayout/DataProviderCollection.php @@ -57,7 +57,7 @@ class DataProviderCollection implements \TYPO3\CMS\Core\SingletonInterface { if (!$dataProvider instanceof DataProviderInterface) { throw new \LogicException( - $className . ' must implement interface TYPO3\\CMS\\Backend\\View\\BackendLayout\\DataProviderInterface', + $className . ' must implement interface ' . \TYPO3\CMS\Backend\View\BackendLayout\DataProviderInterface::class, 1381269811 ); } diff --git a/typo3/sysext/backend/Classes/View/BackendLayoutView.php b/typo3/sysext/backend/Classes/View/BackendLayoutView.php index 41ef5b7ee185..af1836f680f9 100644 --- a/typo3/sysext/backend/Classes/View/BackendLayoutView.php +++ b/typo3/sysext/backend/Classes/View/BackendLayoutView.php @@ -60,7 +60,7 @@ class BackendLayoutView implements \TYPO3\CMS\Core\SingletonInterface { $dataProviderCollection->add( 'default', - 'TYPO3\\CMS\\Backend\\View\\BackendLayout\\DefaultDataProvider' + \TYPO3\CMS\Backend\View\BackendLayout\DefaultDataProvider::class ); if (!empty($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['BackendLayoutDataProvider'])) { diff --git a/typo3/sysext/backend/Classes/View/PageLayoutView.php b/typo3/sysext/backend/Classes/View/PageLayoutView.php index 1ce212d3ed38..0b1c421e50a6 100644 --- a/typo3/sysext/backend/Classes/View/PageLayoutView.php +++ b/typo3/sysext/backend/Classes/View/PageLayoutView.php @@ -549,7 +549,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe // Add new-icon link, header: $newP = $this->newContentElementOnClick($id, $key, $lP); $colTitle = BackendUtility::getProcessedValue('tt_content', 'colPos', $key); - $tcaItems = GeneralUtility::callUserFunction('TYPO3\\CMS\\Backend\\View\\BackendLayoutView->getColPosListItemsParsed', $id, $this); + $tcaItems = GeneralUtility::callUserFunction(\TYPO3\CMS\Backend\View\BackendLayoutView::class . '->getColPosListItemsParsed', $id, $this); foreach ($tcaItems as $item) { if ($item[1] == $key) { $colTitle = $this->getLanguageService()->sL($item[0]); @@ -1451,7 +1451,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe foreach ($drawItemHooks as $hookClass) { $hookObject = GeneralUtility::getUserObj($hookClass); if (!$hookObject instanceof PageLayoutViewDrawItemHookInterface) { - throw new \UnexpectedValueException('$hookObject must implement interface TYPO3\\CMS\\Backend\\View\\PageLayoutViewDrawItemHookInterface', 1218547409); + throw new \UnexpectedValueException('$hookObject must implement interface ' . \TYPO3\CMS\Backend\View\PageLayoutViewDrawItemHookInterface::class, 1218547409); } $hookObject->preProcess($this, $drawItem, $outHeader, $out, $row); } diff --git a/typo3/sysext/backend/Tests/Unit/Configuration/TypoScript/ConditionMatching/ConditionMatcherTest.php b/typo3/sysext/backend/Tests/Unit/Configuration/TypoScript/ConditionMatching/ConditionMatcherTest.php index 944d413bd66e..6898780b5380 100644 --- a/typo3/sysext/backend/Tests/Unit/Configuration/TypoScript/ConditionMatching/ConditionMatcherTest.php +++ b/typo3/sysext/backend/Tests/Unit/Configuration/TypoScript/ConditionMatching/ConditionMatcherTest.php @@ -52,7 +52,7 @@ class ConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { $GLOBALS['TCA'][$this->testTableName] = array('ctrl' => array()); $GLOBALS[$this->testGlobalNamespace] = array(); $this->setUpBackend(); - $this->matchCondition = $this->getMock('TYPO3\\CMS\\Backend\\Configuration\\TypoScript\\ConditionMatching\\ConditionMatcher', array('determineRootline'), array(), '', FALSE); + $this->matchCondition = $this->getMock(\TYPO3\CMS\Backend\Configuration\TypoScript\ConditionMatching\ConditionMatcher::class, array('determineRootline'), array(), '', FALSE); } /** @@ -71,7 +71,7 @@ class ConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * Set up database mock */ private function setUpDatabaseMockForDeterminePageId() { - $GLOBALS['TYPO3_DB'] = $this->getMock('TYPO3\\CMS\\Core\\Database\\DatabaseConnection', array('exec_SELECTquery', 'sql_fetch_assoc', 'sql_free_result')); + $GLOBALS['TYPO3_DB'] = $this->getMock(\TYPO3\CMS\Core\Database\DatabaseConnection::class, array('exec_SELECTquery', 'sql_fetch_assoc', 'sql_free_result')); $GLOBALS['TYPO3_DB']->expects($this->any())->method('exec_SELECTquery')->will($this->returnCallback(array($this, 'determinePageIdByRecordDatabaseExecuteCallback'))); $GLOBALS['TYPO3_DB']->expects($this->any())->method('sql_fetch_assoc')->will($this->returnCallback(array($this, 'determinePageIdByRecordDatabaseFetchCallback'))); } @@ -582,7 +582,7 @@ class ConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function treeLevelConditionMatchesCurrentPageIdWhileEditingNewPage() { - $GLOBALS['SOBE'] = $this->getMock('TYPO3\\CMS\\Backend\\Controller\\EditDocumentController', array(), array(), '', FALSE); + $GLOBALS['SOBE'] = $this->getMock(\TYPO3\CMS\Backend\Controller\EditDocumentController::class, array(), array(), '', FALSE); $GLOBALS['SOBE']->elementsData = array( array( 'table' => 'pages', @@ -604,7 +604,7 @@ class ConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function treeLevelConditionMatchesCurrentPageIdWhileSavingNewPage() { - $GLOBALS['SOBE'] = $this->getMock('TYPO3\\CMS\\Backend\\Controller\\EditDocumentController', array(), array(), '', FALSE); + $GLOBALS['SOBE'] = $this->getMock(\TYPO3\CMS\Backend\Controller\EditDocumentController::class, array(), array(), '', FALSE); $GLOBALS['SOBE']->elementsData = array( array( 'table' => 'pages', @@ -677,7 +677,7 @@ class ConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function PIDupinRootlineConditionMatchesCurrentPageIdWhileEditingNewPage() { - $GLOBALS['SOBE'] = $this->getMock('TYPO3\\CMS\\Backend\\Controller\\EditDocumentController', array(), array(), '', FALSE); + $GLOBALS['SOBE'] = $this->getMock(\TYPO3\CMS\Backend\Controller\EditDocumentController::class, array(), array(), '', FALSE); $GLOBALS['SOBE']->elementsData = array( array( 'table' => 'pages', @@ -699,7 +699,7 @@ class ConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function PIDupinRootlineConditionMatchesCurrentPageIdWhileSavingNewPage() { - $GLOBALS['SOBE'] = $this->getMock('TYPO3\\CMS\\Backend\\Controller\\EditDocumentController', array(), array(), '', FALSE); + $GLOBALS['SOBE'] = $this->getMock(\TYPO3\CMS\Backend\Controller\EditDocumentController::class, array(), array(), '', FALSE); $GLOBALS['SOBE']->elementsData = array( array( 'table' => 'pages', diff --git a/typo3/sysext/backend/Tests/Unit/Controller/File/FileControllerTest.php b/typo3/sysext/backend/Tests/Unit/Controller/File/FileControllerTest.php index 950310d58a6e..8b74a13e438f 100644 --- a/typo3/sysext/backend/Tests/Unit/Controller/File/FileControllerTest.php +++ b/typo3/sysext/backend/Tests/Unit/Controller/File/FileControllerTest.php @@ -48,9 +48,9 @@ class FileControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * Sets up this test case. */ protected function setUp() { - $this->fileResourceMock = $this->getMock('TYPO3\\CMS\\Core\\Resource\\File', array('toArray', 'getModificationTime', 'getExtension'), array(), '', FALSE); - $this->folderResourceMock = $this->getMock('TYPO3\\CMS\\Core\\Resource\\Folder', array('getIdentifier'), array(), '', FALSE); - $this->mockFileProcessor = $this->getMock('TYPO3\\CMS\\Core\\Utility\\File\ExtendedFileUtility', array('getErrorMessages'), array(), '', FALSE); + $this->fileResourceMock = $this->getMock(\TYPO3\CMS\Core\Resource\File::class, array('toArray', 'getModificationTime', 'getExtension'), array(), '', FALSE); + $this->folderResourceMock = $this->getMock(\TYPO3\CMS\Core\Resource\Folder::class, array('getIdentifier'), array(), '', FALSE); + $this->mockFileProcessor = $this->getMock(\TYPO3\CMS\Core\Utility\File\ExtendedFileUtility::class, array('getErrorMessages'), array(), '', FALSE); $this->fileResourceMock->expects($this->any())->method('toArray')->will($this->returnValue(array('id' => 'foo'))); $this->fileResourceMock->expects($this->any())->method('getModificationTime')->will($this->returnValue(123456789)); @@ -61,7 +61,7 @@ class FileControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function flattenResultDataValueFlattensFileAndFolderResourcesButReturnsAnythingElseAsIs() { - $this->fileController = $this->getAccessibleMock('TYPO3\\CMS\\Backend\\Controller\\File\\FileController', array('dummy')); + $this->fileController = $this->getAccessibleMock(\TYPO3\CMS\Backend\Controller\File\FileController::class, array('dummy')); $this->folderResourceMock->expects($this->once())->method('getIdentifier')->will($this->returnValue('bar')); @@ -89,8 +89,8 @@ class FileControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function processAjaxRequestDeleteProcessActuallyDoesNotChangeFileData() { - $this->fileController = $this->getAccessibleMock('TYPO3\\CMS\\Backend\\Controller\\File\\FileController', array('init', 'main')); - $this->mockAjaxRequestHandler = $this->getMock('TYPO3\\CMS\\Core\\Http\\AjaxRequestHandler', array('addContent', 'setContentFormat'), array(), '', FALSE); + $this->fileController = $this->getAccessibleMock(\TYPO3\CMS\Backend\Controller\File\FileController::class, array('init', 'main')); + $this->mockAjaxRequestHandler = $this->getMock(\TYPO3\CMS\Core\Http\AjaxRequestHandler::class, array('addContent', 'setContentFormat'), array(), '', FALSE); $fileData = array('delete' => array(TRUE)); $this->fileController->_set('fileProcessor', $this->mockFileProcessor); @@ -109,8 +109,8 @@ class FileControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function processAjaxRequestEditFileProcessActuallyDoesNotChangeFileData() { - $this->fileController = $this->getAccessibleMock('TYPO3\CMS\\Backend\\Controller\\File\\FileController', array('init', 'main')); - $this->mockAjaxRequestHandler = $this->getMock('TYPO3\\CMS\\Core\\Http\\AjaxRequestHandler', array('addContent', 'setContentFormat'), array(), '', FALSE); + $this->fileController = $this->getAccessibleMock(\TYPO3\CMS\Backend\Controller\File\FileController::class, array('init', 'main')); + $this->mockAjaxRequestHandler = $this->getMock(\TYPO3\CMS\Core\Http\AjaxRequestHandler::class, array('addContent', 'setContentFormat'), array(), '', FALSE); $fileData = array('editfile' => array(TRUE)); $this->fileController->_set('fileProcessor', $this->mockFileProcessor); @@ -129,8 +129,8 @@ class FileControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function processAjaxRequestUnzipProcessActuallyDoesNotChangeFileData() { - $this->fileController = $this->getAccessibleMock('TYPO3\\CMS\\Backend\\Controller\\File\\FileController', array('init', 'main')); - $this->mockAjaxRequestHandler = $this->getMock('TYPO3\\CMS\\Core\\Http\\AjaxRequestHandler', array('addContent', 'setContentFormat'), array(), '', FALSE); + $this->fileController = $this->getAccessibleMock(\TYPO3\CMS\Backend\Controller\File\FileController::class, array('init', 'main')); + $this->mockAjaxRequestHandler = $this->getMock(\TYPO3\CMS\Core\Http\AjaxRequestHandler::class, array('addContent', 'setContentFormat'), array(), '', FALSE); $fileData = array('unzip' => array(TRUE)); $this->fileController->_set('fileProcessor', $this->mockFileProcessor); @@ -149,8 +149,8 @@ class FileControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function processAjaxRequestUploadProcess() { - $this->fileController = $this->getAccessibleMock('TYPO3\\CMS\Backend\\Controller\\File\\FileController', array('init', 'main')); - $this->mockAjaxRequestHandler = $this->getMock('TYPO3\\CMS\\Core\\Http\\AjaxRequestHandler', array('addContent', 'setContentFormat'), array(), '', FALSE); + $this->fileController = $this->getAccessibleMock(\TYPO3\CMS\Backend\Controller\File\FileController::class, array('init', 'main')); + $this->mockAjaxRequestHandler = $this->getMock(\TYPO3\CMS\Core\Http\AjaxRequestHandler::class, array('addContent', 'setContentFormat'), array(), '', FALSE); $fileData = array('upload' => array(array($this->fileResourceMock))); $result = array('upload' => array(array( diff --git a/typo3/sysext/backend/Tests/Unit/Form/Element/InlineElementTest.php b/typo3/sysext/backend/Tests/Unit/Form/Element/InlineElementTest.php index a99cd5e828d4..eb1f63f58c00 100644 --- a/typo3/sysext/backend/Tests/Unit/Form/Element/InlineElementTest.php +++ b/typo3/sysext/backend/Tests/Unit/Form/Element/InlineElementTest.php @@ -31,7 +31,7 @@ class InlineElementTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { protected function setUp() { // @todo Use $this->buildAccessibleProxy() if properties are protected $this->subject = new \TYPO3\CMS\Backend\Form\Element\InlineElement(); - $this->subject->fObj = $this->getMock('TYPO3\\CMS\\Backend\\Form\\FormEngine', array(), array(), '', FALSE); + $this->subject->fObj = $this->getMock(\TYPO3\CMS\Backend\Form\FormEngine::class, array(), array(), '', FALSE); } /** diff --git a/typo3/sysext/backend/Tests/Unit/Form/ElementConditionMatcherTest.php b/typo3/sysext/backend/Tests/Unit/Form/ElementConditionMatcherTest.php index 9f8d1bef82c0..a18bb5076a16 100644 --- a/typo3/sysext/backend/Tests/Unit/Form/ElementConditionMatcherTest.php +++ b/typo3/sysext/backend/Tests/Unit/Form/ElementConditionMatcherTest.php @@ -339,7 +339,7 @@ class ElementConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ public function matchHideForNonAdminsReturnsTrueIfBackendUserIsAdmin() { /** @var $backendUserMock \TYPO3\CMS\Core\Authentication\BackendUserAuthentication|\PHPUnit_Framework_MockObject_MockObject */ - $backendUserMock = $this->getMock('TYPO3\\CMS\\Core\\Authentication\\BackendUserAuthentication'); + $backendUserMock = $this->getMock(\TYPO3\CMS\Core\Authentication\BackendUserAuthentication::class); $backendUserMock ->expects($this->once()) ->method('isAdmin') @@ -353,7 +353,7 @@ class ElementConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ public function matchHideForNonAdminsReturnsFalseIfBackendUserIsNotAdmin() { /** @var $backendUserMock \TYPO3\CMS\Core\Authentication\BackendUserAuthentication|\PHPUnit_Framework_MockObject_MockObject */ - $backendUserMock = $this->getMock('TYPO3\\CMS\\Core\\Authentication\\BackendUserAuthentication'); + $backendUserMock = $this->getMock(\TYPO3\CMS\Core\Authentication\BackendUserAuthentication::class); $backendUserMock ->expects($this->once()) ->method('isAdmin') @@ -367,7 +367,7 @@ class ElementConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ public function matchHideL10NSiblingsExceptAdminReturnsTrueIfBackendUserIsAdmin() { /** @var $backendUserMock \TYPO3\CMS\Core\Authentication\BackendUserAuthentication|\PHPUnit_Framework_MockObject_MockObject */ - $backendUserMock = $this->getMock('TYPO3\\CMS\\Core\\Authentication\\BackendUserAuthentication'); + $backendUserMock = $this->getMock(\TYPO3\CMS\Core\Authentication\BackendUserAuthentication::class); $backendUserMock ->expects($this->once()) ->method('isAdmin') @@ -381,7 +381,7 @@ class ElementConditionMatcherTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ public function matchHideL10NSiblingsExceptAdminReturnsFalseIfBackendUserIsNotAdmin() { /** @var $backendUserMock \TYPO3\CMS\Core\Authentication\BackendUserAuthentication|\PHPUnit_Framework_MockObject_MockObject */ - $backendUserMock = $this->getMock('TYPO3\\CMS\\Core\\Authentication\\BackendUserAuthentication'); + $backendUserMock = $this->getMock(\TYPO3\CMS\Core\Authentication\BackendUserAuthentication::class); $backendUserMock ->expects($this->once()) ->method('isAdmin') diff --git a/typo3/sysext/backend/Tests/Unit/Form/FormEngineTest.php b/typo3/sysext/backend/Tests/Unit/Form/FormEngineTest.php index b6a953ced85f..72df9123b676 100644 --- a/typo3/sysext/backend/Tests/Unit/Form/FormEngineTest.php +++ b/typo3/sysext/backend/Tests/Unit/Form/FormEngineTest.php @@ -30,7 +30,7 @@ class FormEngineTest extends UnitTestCase { * Sets up this test case. */ protected function setUp() { - $this->subject = $this->getMock('TYPO3\\CMS\\Backend\\Form\\FormEngine', array('dummy'), array(), '', FALSE); + $this->subject = $this->getMock(\TYPO3\CMS\Backend\Form\FormEngine::class, array('dummy'), array(), '', FALSE); } /** diff --git a/typo3/sysext/backend/Tests/Unit/Module/ModuleControllerTest.php b/typo3/sysext/backend/Tests/Unit/Module/ModuleControllerTest.php index 82d711ebf2d7..5aee283c579f 100644 --- a/typo3/sysext/backend/Tests/Unit/Module/ModuleControllerTest.php +++ b/typo3/sysext/backend/Tests/Unit/Module/ModuleControllerTest.php @@ -27,7 +27,7 @@ class ModuleControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { protected $moduleController; protected function setUp() { - $this->moduleController = $this->getAccessibleMock('TYPO3\\CMS\\Backend\\Module\\ModuleController', array('getLanguageService'), array(), '', FALSE); + $this->moduleController = $this->getAccessibleMock(\TYPO3\CMS\Backend\Module\ModuleController::class, array('getLanguageService'), array(), '', FALSE); } /** @@ -35,7 +35,7 @@ class ModuleControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ public function createEntryFromRawDataGeneratesMenuEntry() { $entry = $this->moduleController->_call('createEntryFromRawData', array()); - $this->assertInstanceOf('TYPO3\\CMS\\Backend\\Domain\\Model\\Module\\BackendModule', $entry); + $this->assertInstanceOf(\TYPO3\CMS\Backend\Domain\Model\Module\BackendModule::class, $entry); } /** @@ -54,7 +54,7 @@ class ModuleControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { 'navigationComponentId' => 'navigationComponentIdTest' ); - $languageServiceMock = $this->getMock('TYPO3\\CMS\\Lang\\LanguageService', array(), array(), '', FALSE); + $languageServiceMock = $this->getMock(\TYPO3\CMS\Lang\LanguageService::class, array(), array(), '', FALSE); $languageServiceMock->expects($this->once())->method('sL')->will($this->returnValue('titleTest')); $this->moduleController->expects($this->once())->method('getLanguageService')->will($this->returnValue($languageServiceMock)); diff --git a/typo3/sysext/backend/Tests/Unit/Tree/Pagetree/DataProviderTest.php b/typo3/sysext/backend/Tests/Unit/Tree/Pagetree/DataProviderTest.php index ea931559838d..f5eaff415960 100644 --- a/typo3/sysext/backend/Tests/Unit/Tree/Pagetree/DataProviderTest.php +++ b/typo3/sysext/backend/Tests/Unit/Tree/Pagetree/DataProviderTest.php @@ -33,7 +33,7 @@ class DataProviderTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/tree/pagetree/class.t3lib_tree_pagetree_dataprovider.php']['postProcessCollections'] = array(); $GLOBALS['LOCKED_RECORDS'] = array(); /** @var $backendUserMock \TYPO3\CMS\Core\Authentication\BackendUserAuthentication|\PHPUnit_Framework_MockObject_MockObject */ - $backendUserMock = $this->getMock('TYPO3\\CMS\\Core\\Authentication\\BackendUserAuthentication', array(), array(), '', FALSE); + $backendUserMock = $this->getMock(\TYPO3\CMS\Core\Authentication\BackendUserAuthentication::class, array(), array(), '', FALSE); $GLOBALS['BE_USER'] = $backendUserMock; $this->subject = new \TYPO3\CMS\Backend\Tree\Pagetree\DataProvider(); diff --git a/typo3/sysext/backend/Tests/Unit/Tree/TreeNodeCollectionTest.php b/typo3/sysext/backend/Tests/Unit/Tree/TreeNodeCollectionTest.php index 67b657a809d8..8a89566c404b 100644 --- a/typo3/sysext/backend/Tests/Unit/Tree/TreeNodeCollectionTest.php +++ b/typo3/sysext/backend/Tests/Unit/Tree/TreeNodeCollectionTest.php @@ -26,12 +26,12 @@ class TreeNodeCollectionTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ public function sortNodes() { $nodeCollection = new \TYPO3\CMS\Backend\Tree\TreeNodeCollection(array( - array('serializeClassName' => 'TYPO3\\CMS\\Backend\\Tree\\TreeNode', 'id' => 15), - array('serializeClassName' => 'TYPO3\\CMS\\Backend\\Tree\\TreeNode', 'id' => 25), - array('serializeClassName' => 'TYPO3\\CMS\\Backend\\Tree\\TreeNode', 'id' => 5), - array('serializeClassName' => 'TYPO3\\CMS\\Backend\\Tree\\TreeNode', 'id' => 2), - array('serializeClassName' => 'TYPO3\\CMS\\Backend\\Tree\\TreeNode', 'id' => 150), - array('serializeClassName' => 'TYPO3\\CMS\\Backend\\Tree\\TreeNode', 'id' => 67) + array('serializeClassName' => \TYPO3\CMS\Backend\Tree\TreeNode::class, 'id' => 15), + array('serializeClassName' => \TYPO3\CMS\Backend\Tree\TreeNode::class, 'id' => 25), + array('serializeClassName' => \TYPO3\CMS\Backend\Tree\TreeNode::class, 'id' => 5), + array('serializeClassName' => \TYPO3\CMS\Backend\Tree\TreeNode::class, 'id' => 2), + array('serializeClassName' => \TYPO3\CMS\Backend\Tree\TreeNode::class, 'id' => 150), + array('serializeClassName' => \TYPO3\CMS\Backend\Tree\TreeNode::class, 'id' => 67) )); $nodeCollection->asort(); $expected = array(2, 5, 15, 25, 67, 150); diff --git a/typo3/sysext/backend/Tests/Unit/Utility/BackendUtilityTest.php b/typo3/sysext/backend/Tests/Unit/Utility/BackendUtilityTest.php index 2cd3954bed30..e7f777cfe03f 100644 --- a/typo3/sysext/backend/Tests/Unit/Utility/BackendUtilityTest.php +++ b/typo3/sysext/backend/Tests/Unit/Utility/BackendUtilityTest.php @@ -566,7 +566,7 @@ class BackendUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { ) ); // Stub LanguageService and let sL() return the same value that came in again - $GLOBALS['LANG'] = $this->getMock('TYPO3\\CMS\\Lang\\LanguageService', array(), array(), '', FALSE); + $GLOBALS['LANG'] = $this->getMock(\TYPO3\CMS\Lang\LanguageService::class, array(), array(), '', FALSE); $GLOBALS['LANG']->expects($this->any())->method('sL') ->will($this->returnCallback( function($name) { @@ -599,9 +599,9 @@ class BackendUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { ) ); // Stub LanguageService and let sL() return the same value that came in again - $GLOBALS['LANG'] = $this->getMock('TYPO3\\CMS\\Lang\\LanguageService', array(), array(), '', FALSE); + $GLOBALS['LANG'] = $this->getMock(\TYPO3\CMS\Lang\LanguageService::class, array(), array(), '', FALSE); $GLOBALS['LANG']->charSet = 'utf-8'; - $GLOBALS['LANG']->csConvObj = $this->getMock('TYPO3\\CMS\\Core\\Charset\\CharsetConverter'); + $GLOBALS['LANG']->csConvObj = $this->getMock(\TYPO3\CMS\Core\Charset\CharsetConverter::class); $GLOBALS['LANG']->expects($this->any())->method('sL') ->will($this->returnCallback( function($name) { @@ -639,9 +639,9 @@ class BackendUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { ) ); // Stub LanguageService and let sL() return the same value that came in again - $GLOBALS['LANG'] = $this->getMock('TYPO3\\CMS\\Lang\\LanguageService', array(), array(), '', FALSE); + $GLOBALS['LANG'] = $this->getMock(\TYPO3\CMS\Lang\LanguageService::class, array(), array(), '', FALSE); $GLOBALS['LANG']->charSet = 'utf-8'; - $GLOBALS['LANG']->csConvObj = $this->getMock('TYPO3\\CMS\\Core\\Charset\\CharsetConverter'); + $GLOBALS['LANG']->csConvObj = $this->getMock(\TYPO3\CMS\Core\Charset\CharsetConverter::class); $GLOBALS['LANG']->expects($this->any())->method('sL') ->will($this->returnCallback( function($name) { @@ -778,7 +778,7 @@ class BackendUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { $GLOBALS['TCA'] = $tca; // Stub LanguageService and let sL() return the same value that came in again - $GLOBALS['LANG'] = $this->getMock('TYPO3\\CMS\\Lang\\LanguageService', array(), array(), '', FALSE); + $GLOBALS['LANG'] = $this->getMock(\TYPO3\CMS\Lang\LanguageService::class, array(), array(), '', FALSE); $GLOBALS['LANG']->expects($this->any())->method('sL') ->will($this->returnCallback( function($name) { @@ -882,7 +882,7 @@ class BackendUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { ); // Stub LanguageService and let sL() return the same value that came in again - $GLOBALS['LANG'] = $this->getMock('TYPO3\\CMS\\Lang\\LanguageService', array(), array(), '', FALSE); + $GLOBALS['LANG'] = $this->getMock(\TYPO3\CMS\Lang\LanguageService::class, array(), array(), '', FALSE); $GLOBALS['LANG']->expects($this->any())->method('sL') ->will($this->returnCallback( function($name) { @@ -1141,7 +1141,7 @@ class BackendUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ public function replaceMarkersInWhereClauseReturnsValidWhereClause($whereClause, $tsConfig, $expected) { // Mock TYPO3_DB and let it return same values that came in - $GLOBALS['TYPO3_DB'] = $this->getMock('TYPO3\\CMS\\Core\\Database\\DatabaseConnection', array(), array(), '', FALSE); + $GLOBALS['TYPO3_DB'] = $this->getMock(\TYPO3\CMS\Core\Database\DatabaseConnection::class, array(), array(), '', FALSE); $GLOBALS['TYPO3_DB']->expects($this->any())->method('quoteStr') ->will($this->returnCallback( function($quoteStr, $table) { @@ -1167,7 +1167,7 @@ class BackendUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @test */ public function replaceMarkersInWhereClauseCleansIdList() { - $GLOBALS['TYPO3_DB'] = $this->getMock('TYPO3\\CMS\\Core\\Database\\DatabaseConnection', array(), array(), '', FALSE); + $GLOBALS['TYPO3_DB'] = $this->getMock(\TYPO3\CMS\Core\Database\DatabaseConnection::class, array(), array(), '', FALSE); $GLOBALS['TYPO3_DB']->expects($this->once())->method('cleanIntList')->with('1,a,2,b,3,c'); $where = ' AND dummytable.uid IN (###PAGE_TSCONFIG_IDLIST###)'; $tsConfig = array( @@ -1195,7 +1195,7 @@ class BackendUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { ) ); - $GLOBALS['BE_USER'] = $this->getMock('TYPO3\\CMS\\Core\\Authentication\\BackendUserAuthentication', array(), array(), '', FALSE); + $GLOBALS['BE_USER'] = $this->getMock(\TYPO3\CMS\Core\Authentication\BackendUserAuthentication::class, array(), array(), '', FALSE); $GLOBALS['BE_USER']->expects($this->at(0))->method('getTSConfig')->will($this->returnValue($completeConfiguration)); $GLOBALS['BE_USER']->expects($this->at(1))->method('getTSConfig')->will($this->returnValue(array('value' => NULL, 'properties' => NULL))); @@ -1353,11 +1353,11 @@ class BackendUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ public function replaceL10nModeFieldsReplacesFields($table, $row, $tca, $originalRow, $expected) { $GLOBALS['TCA'] = $tca; - $GLOBALS['TYPO3_DB'] = $this->getMock('TYPO3\\CMS\\Core\\Database\\DatabaseConnection'); + $GLOBALS['TYPO3_DB'] = $this->getMock(\TYPO3\CMS\Core\Database\DatabaseConnection::class); $GLOBALS['TYPO3_DB']->expects($this->any())->method('exec_SELECTgetSingleRow')->will($this->returnValue($originalRow)); /** @var \PHPUnit_Framework_MockObject_MockObject|\TYPO3\CMS\Core\Tests\AccessibleObjectInterface|\TYPO3\CMS\Backend\Utility\BackendUtility $subject */ - $subject = $this->getAccessibleMock('TYPO3\\CMS\\Backend\\Utility\\BackendUtility', array('dummy')); + $subject = $this->getAccessibleMock(\TYPO3\CMS\Backend\Utility\BackendUtility::class, array('dummy')); $this->assertSame($expected, $subject->_call('replaceL10nModeFields', $table, $row)); } } diff --git a/typo3/sysext/backend/Tests/Unit/Utility/IconUtilityTest.php b/typo3/sysext/backend/Tests/Unit/Utility/IconUtilityTest.php index ff03884224c7..804abcd0c57d 100644 --- a/typo3/sysext/backend/Tests/Unit/Utility/IconUtilityTest.php +++ b/typo3/sysext/backend/Tests/Unit/Utility/IconUtilityTest.php @@ -74,7 +74,7 @@ class IconUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @return \TYPO3\CMS\Core\Resource\Folder */ protected function getTestSubjectFolderObject($identifier) { - $mockedStorage = $this->getMock('TYPO3\\CMS\\Core\\Resource\\ResourceStorage', array(), array(), '', FALSE); + $mockedStorage = $this->getMock(\TYPO3\CMS\Core\Resource\ResourceStorage::class, array(), array(), '', FALSE); $mockedStorage->expects($this->any())->method('getRootLevelFolder')->will($this->returnValue( new \TYPO3\CMS\Core\Resource\Folder($mockedStorage, '/', '/') )); @@ -89,8 +89,8 @@ class IconUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { * @return \TYPO3\CMS\Core\Resource\File */ protected function getTestSubjectFileObject($extension) { - $mockedStorage = $this->getMock('TYPO3\\CMS\\Core\\Resource\\ResourceStorage', array(), array(), '', FALSE); - $mockedFile = $this->getMock('TYPO3\\CMS\\Core\\Resource\\File', array(), array(array(), $mockedStorage)); + $mockedStorage = $this->getMock(\TYPO3\CMS\Core\Resource\ResourceStorage::class, array(), array(), '', FALSE); + $mockedFile = $this->getMock(\TYPO3\CMS\Core\Resource\File::class, array(), array(array(), $mockedStorage)); $mockedFile->expects($this->once())->method('getExtension')->will($this->returnValue($extension)); return $mockedFile; @@ -755,7 +755,7 @@ class IconUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { ); $classReference = uniqid('user_overrideResourceIconHook'); $folderObject = $this->getTestSubjectFolderObject('/test'); - $hookMock = $this->getMock('TYPO3\\CMS\\Backend\\Utility\\IconUtilityOverrideResourceIconHookInterface', array('overrideResourceIcon'), array(), $classReference); + $hookMock = $this->getMock(\TYPO3\CMS\Backend\Utility\IconUtilityOverrideResourceIconHookInterface::class, array('overrideResourceIcon'), array(), $classReference); $hookMock->expects($this->once())->method('overrideResourceIcon'); $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_iconworks.php']['overrideResourceIcon'][$classReference] = $classReference; $GLOBALS['T3_VAR']['getUserObj'][$classReference] = $hookMock; diff --git a/typo3/sysext/backend/Tests/Unit/View/BackendLayout/BackendLayoutCollectionTest.php b/typo3/sysext/backend/Tests/Unit/View/BackendLayout/BackendLayoutCollectionTest.php index a05812b5a5c2..7ab4c9594cb1 100644 --- a/typo3/sysext/backend/Tests/Unit/View/BackendLayout/BackendLayoutCollectionTest.php +++ b/typo3/sysext/backend/Tests/Unit/View/BackendLayout/BackendLayoutCollectionTest.php @@ -48,7 +48,7 @@ class BackendLayoutCollectionTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { $identifier = uniqid('identifier'); $backendLayoutCollection = new \TYPO3\CMS\Backend\View\BackendLayout\BackendLayoutCollection($identifier); $backendLayoutIdentifier = uniqid('identifier__'); - $backendLayoutMock = $this->getMock('TYPO3\\CMS\\Backend\\View\\BackendLayout\\BackendLayout', array('getIdentifier'), array(), '', FALSE); + $backendLayoutMock = $this->getMock(\TYPO3\CMS\Backend\View\BackendLayout\BackendLayout::class, array('getIdentifier'), array(), '', FALSE); $backendLayoutMock->expects($this->once())->method('getIdentifier')->will($this->returnValue($backendLayoutIdentifier)); $backendLayoutCollection->add($backendLayoutMock); @@ -62,9 +62,9 @@ class BackendLayoutCollectionTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { $identifier = uniqid('identifier'); $backendLayoutCollection = new \TYPO3\CMS\Backend\View\BackendLayout\BackendLayoutCollection($identifier); $backendLayoutIdentifier = uniqid('identifier'); - $firstBackendLayoutMock = $this->getMock('TYPO3\\CMS\\Backend\\View\\BackendLayout\\BackendLayout', array('getIdentifier'), array(), '', FALSE); + $firstBackendLayoutMock = $this->getMock(\TYPO3\CMS\Backend\View\BackendLayout\BackendLayout::class, array('getIdentifier'), array(), '', FALSE); $firstBackendLayoutMock->expects($this->once())->method('getIdentifier')->will($this->returnValue($backendLayoutIdentifier)); - $secondBackendLayoutMock = $this->getMock('TYPO3\\CMS\\Backend\\View\\BackendLayout\\BackendLayout', array('getIdentifier'), array(), '', FALSE); + $secondBackendLayoutMock = $this->getMock(\TYPO3\CMS\Backend\View\BackendLayout\BackendLayout::class, array('getIdentifier'), array(), '', FALSE); $secondBackendLayoutMock->expects($this->once())->method('getIdentifier')->will($this->returnValue($backendLayoutIdentifier)); $backendLayoutCollection->add($firstBackendLayoutMock); @@ -78,7 +78,7 @@ class BackendLayoutCollectionTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { $identifier = uniqid('identifier'); $backendLayoutCollection = new \TYPO3\CMS\Backend\View\BackendLayout\BackendLayoutCollection($identifier); $backendLayoutIdentifier = uniqid('identifier'); - $backendLayoutMock = $this->getMock('TYPO3\\CMS\\Backend\\View\\BackendLayout\\BackendLayout', array('getIdentifier'), array(), '', FALSE); + $backendLayoutMock = $this->getMock(\TYPO3\CMS\Backend\View\BackendLayout\BackendLayout::class, array('getIdentifier'), array(), '', FALSE); $backendLayoutMock->expects($this->once())->method('getIdentifier')->will($this->returnValue($backendLayoutIdentifier)); $backendLayoutCollection->add($backendLayoutMock); diff --git a/typo3/sysext/backend/Tests/Unit/View/BackendLayout/DataProviderCollectionTest.php b/typo3/sysext/backend/Tests/Unit/View/BackendLayout/DataProviderCollectionTest.php index 94cd2dbe2953..92d2c366af91 100644 --- a/typo3/sysext/backend/Tests/Unit/View/BackendLayout/DataProviderCollectionTest.php +++ b/typo3/sysext/backend/Tests/Unit/View/BackendLayout/DataProviderCollectionTest.php @@ -61,8 +61,8 @@ class DataProviderCollectionTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { public function defaultBackendLayoutIsFound() { $backendLayoutIdentifier = uniqid('identifier'); - $dataProviderMock = $this->getMock('TYPO3\\CMS\\Backend\\View\\BackendLayout\\DefaultDataProvider', array('getBackendLayout'), array(), '', FALSE); - $backendLayoutMock = $this->getMock('TYPO3\\CMS\\Backend\\View\\BackendLayout\\BackendLayout', array('getIdentifier'), array(), '', FALSE); + $dataProviderMock = $this->getMock(\TYPO3\CMS\Backend\View\BackendLayout\DefaultDataProvider::class, array('getBackendLayout'), array(), '', FALSE); + $backendLayoutMock = $this->getMock(\TYPO3\CMS\Backend\View\BackendLayout\BackendLayout::class, array('getIdentifier'), array(), '', FALSE); $backendLayoutMock->expects($this->any())->method('getIdentifier')->will($this->returnValue($backendLayoutIdentifier)); $dataProviderMock->expects($this->once())->method('getBackendLayout')->will($this->returnValue($backendLayoutMock)); @@ -80,8 +80,8 @@ class DataProviderCollectionTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { $dataProviderIdentifier = uniqid('custom'); $backendLayoutIdentifier = uniqid('identifier'); - $dataProviderMock = $this->getMock('TYPO3\\CMS\\Backend\\View\\BackendLayout\\DefaultDataProvider', array('getBackendLayout'), array(), '', FALSE); - $backendLayoutMock = $this->getMock('TYPO3\\CMS\\Backend\\View\\BackendLayout\\BackendLayout', array('getIdentifier'), array(), '', FALSE); + $dataProviderMock = $this->getMock(\TYPO3\CMS\Backend\View\BackendLayout\DefaultDataProvider::class, array('getBackendLayout'), array(), '', FALSE); + $backendLayoutMock = $this->getMock(\TYPO3\CMS\Backend\View\BackendLayout\BackendLayout::class, array('getIdentifier'), array(), '', FALSE); $backendLayoutMock->expects($this->any())->method('getIdentifier')->will($this->returnValue($backendLayoutIdentifier)); $dataProviderMock->expects($this->once())->method('getBackendLayout')->will($this->returnValue($backendLayoutMock)); diff --git a/typo3/sysext/backend/Tests/Unit/View/BackendLayoutViewTest.php b/typo3/sysext/backend/Tests/Unit/View/BackendLayoutViewTest.php index 41d8d30c9957..2ed25c44b94c 100644 --- a/typo3/sysext/backend/Tests/Unit/View/BackendLayoutViewTest.php +++ b/typo3/sysext/backend/Tests/Unit/View/BackendLayoutViewTest.php @@ -31,7 +31,7 @@ class BackendLayoutViewTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ protected function setUp() { $this->backendLayoutView = $this->getAccessibleMock( - 'TYPO3\\CMS\\Backend\\View\\BackendLayoutView', + \TYPO3\CMS\Backend\View\BackendLayoutView::class, array('getPage', 'getRootLine'), array(), '', FALSE ); diff --git a/typo3/sysext/backend/Tests/Unit/View/ModuleMenuViewTest.php b/typo3/sysext/backend/Tests/Unit/View/ModuleMenuViewTest.php index d9524f47f3a8..d8d401652fb9 100644 --- a/typo3/sysext/backend/Tests/Unit/View/ModuleMenuViewTest.php +++ b/typo3/sysext/backend/Tests/Unit/View/ModuleMenuViewTest.php @@ -25,7 +25,7 @@ class ModuleMenuViewTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { public function unsetHiddenModulesUnsetsHiddenModules() { /** @var \TYPO3\CMS\Backend\View\ModuleMenuView|\PHPUnit_Framework_MockObject_MockObject|\TYPO3\CMS\Core\Tests\AccessibleObjectInterface $moduleMenuViewMock */ $moduleMenuViewMock = $this->getAccessibleMock( - 'TYPO3\\CMS\\Backend\\View\\ModuleMenuView', + \TYPO3\CMS\Backend\View\ModuleMenuView::class, array('dummy'), array(), '', @@ -59,7 +59,7 @@ class ModuleMenuViewTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { ), ); - $GLOBALS['BE_USER'] = $this->getMock('TYPO3\\CMS\\Core\\Authentication\\BackendUserAuthentication', array(), array(), '', FALSE); + $GLOBALS['BE_USER'] = $this->getMock(\TYPO3\CMS\Core\Authentication\BackendUserAuthentication::class, array(), array(), '', FALSE); $GLOBALS['BE_USER']->expects($this->any())->method('getTSConfig')->will($this->returnValue($userTsFixture)); $expectedResult = array( diff --git a/typo3/sysext/backend/ext_localconf.php b/typo3/sysext/backend/ext_localconf.php index 54f61079b8cf..32879a2d6fe5 100644 --- a/typo3/sysext/backend/ext_localconf.php +++ b/typo3/sysext/backend/ext_localconf.php @@ -3,17 +3,17 @@ defined('TYPO3_MODE') or die(); if (TYPO3_MODE === 'BE') { \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Extbase\SignalSlot\Dispatcher::class)->connect( - 'TYPO3\\CMS\\Core\\Tree\\TableConfiguration\\TableConfiguration\\DatabaseTreeDataProvider', + \TYPO3\CMS\Core\Tree\TableConfiguration\DatabaseTreeDataProvider::class, \TYPO3\CMS\Core\Tree\TableConfiguration\DatabaseTreeDataProvider::SIGNAL_PostProcessTreeData, - 'TYPO3\\CMS\\Backend\\Security\\CategoryPermissionsAspect', + \TYPO3\CMS\Backend\Security\CategoryPermissionsAspect::class, 'addUserPermissionsToCategoryTreeData' ); - $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = 'TYPO3\\CMS\\Backend\\Backend\\ToolbarItems\\ClearCacheToolbarItem'; - $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = 'TYPO3\\CMS\\Backend\\Backend\\ToolbarItems\\HelpToolbarItem'; - $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = 'TYPO3\\CMS\\Backend\\Backend\\ToolbarItems\\LiveSearchToolbarItem'; - $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = 'TYPO3\\CMS\\Backend\\Backend\\ToolbarItems\\ShortcutToolbarItem'; - $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = 'TYPO3\\CMS\\Backend\\Backend\\ToolbarItems\\UserToolbarItem'; + $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = \TYPO3\CMS\Backend\Backend\ToolbarItems\ClearCacheToolbarItem::class; + $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = \TYPO3\CMS\Backend\Backend\ToolbarItems\HelpToolbarItem::class; + $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = \TYPO3\CMS\Backend\Backend\ToolbarItems\LiveSearchToolbarItem::class; + $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = \TYPO3\CMS\Backend\Backend\ToolbarItems\ShortcutToolbarItem::class; + $GLOBALS['TYPO3_CONF_VARS']['BE']['toolbarItems'][] = \TYPO3\CMS\Backend\Backend\ToolbarItems\UserToolbarItem::class; } -$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tsfebeuserauth.php']['frontendEditingController']['default'] = 'TYPO3\\CMS\\Core\\FrontendEditing\\FrontendEditingController'; +$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tsfebeuserauth.php']['frontendEditingController']['default'] = \TYPO3\CMS\Core\FrontendEditing\FrontendEditingController::class; -- GitLab