From 8d3b013b298007a5196d82714d00091272607918 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20B=C3=BCrk?= <stefan@buerk.tech> Date: Sat, 18 Jun 2022 21:21:05 +0200 Subject: [PATCH] [TASK] Use proper PSR-4 compatible namespaces 2 This patch adjustes invalid namespaces uses in some files to ensure PSR-4 loading compatibility. Additionally the superflous use statements are removed. Resolves: #97792 Releases: main, 11.5 Change-Id: I9a0bae0a2e59cf8dce77f131350db488c9688840 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/74954 Tested-by: core-ci <typo3@b13.com> Tested-by: Christian Kuhn <lolli@schwarzbu.ch> Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch> --- .../Acceptance/Application/Dashboard/DashboardModuleCest.php | 2 +- .../Acceptance/Application/Workspace/WorkspaceModuleCest.php | 2 +- .../core/Tests/Functional/Cache/Core/ClassAliasLoaderTest.php | 2 +- .../SoftReference/EmailSoftReferenceParserTest.php | 4 +--- .../SoftReference/ExtensionPathSoftReferenceParserTest.php | 4 +--- .../SoftReference/NotifySoftReferenceParserTest.php | 4 +--- .../SoftReference/SubstituteSoftReferenceParserTest.php | 4 +--- .../SoftReference/TypoLinkSoftReferenceParserTest.php | 3 +-- .../SoftReference/TypoLinkTagSoftReferenceParserTest.php | 3 +-- .../DataHandling/SoftReference/UrlSoftReferenceParserTest.php | 4 +--- 10 files changed, 10 insertions(+), 22 deletions(-) diff --git a/typo3/sysext/core/Tests/Acceptance/Application/Dashboard/DashboardModuleCest.php b/typo3/sysext/core/Tests/Acceptance/Application/Dashboard/DashboardModuleCest.php index 525b9e5b1013..b0128e5dc8f6 100644 --- a/typo3/sysext/core/Tests/Acceptance/Application/Dashboard/DashboardModuleCest.php +++ b/typo3/sysext/core/Tests/Acceptance/Application/Dashboard/DashboardModuleCest.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Core\Tests\Acceptance\Application\Info; +namespace TYPO3\CMS\Core\Tests\Acceptance\Application\Dashboard; use TYPO3\CMS\Core\Tests\Acceptance\Support\ApplicationTester; use TYPO3\CMS\Core\Tests\Acceptance\Support\Helper\ModalDialog; diff --git a/typo3/sysext/core/Tests/Acceptance/Application/Workspace/WorkspaceModuleCest.php b/typo3/sysext/core/Tests/Acceptance/Application/Workspace/WorkspaceModuleCest.php index 1e9f769721f2..736a9fd8d6f6 100644 --- a/typo3/sysext/core/Tests/Acceptance/Application/Workspace/WorkspaceModuleCest.php +++ b/typo3/sysext/core/Tests/Acceptance/Application/Workspace/WorkspaceModuleCest.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Core\Tests\Acceptance\Application\Page; +namespace TYPO3\CMS\Core\Tests\Acceptance\Application\Workspace; use TYPO3\CMS\Core\Tests\Acceptance\Support\ApplicationTester; use TYPO3\CMS\Core\Tests\Acceptance\Support\Helper\ModalDialog; diff --git a/typo3/sysext/core/Tests/Functional/Cache/Core/ClassAliasLoaderTest.php b/typo3/sysext/core/Tests/Functional/Cache/Core/ClassAliasLoaderTest.php index a389cac07790..7f7e7383dca5 100644 --- a/typo3/sysext/core/Tests/Functional/Cache/Core/ClassAliasLoaderTest.php +++ b/typo3/sysext/core/Tests/Functional/Cache/Core/ClassAliasLoaderTest.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Core\Tests\Functional\Core; +namespace TYPO3\CMS\Core\Tests\Functional\Cache\Core; use Prophecy\PhpUnit\ProphecyTrait; use TYPO3\TestingFramework\Core\Functional\FunctionalTestCase; diff --git a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/EmailSoftReferenceParserTest.php b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/EmailSoftReferenceParserTest.php index c0f4db1143f3..75c750095d7b 100644 --- a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/EmailSoftReferenceParserTest.php +++ b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/EmailSoftReferenceParserTest.php @@ -15,9 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace Unit\DataHandling\SoftReference; - -use TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference\AbstractSoftReferenceParserTest; +namespace TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference; class EmailSoftReferenceParserTest extends AbstractSoftReferenceParserTest { diff --git a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/ExtensionPathSoftReferenceParserTest.php b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/ExtensionPathSoftReferenceParserTest.php index 053e95faad9f..6118ad1a558e 100644 --- a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/ExtensionPathSoftReferenceParserTest.php +++ b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/ExtensionPathSoftReferenceParserTest.php @@ -15,9 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace Unit\DataHandling\SoftReference; - -use TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference\AbstractSoftReferenceParserTest; +namespace TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference; class ExtensionPathSoftReferenceParserTest extends AbstractSoftReferenceParserTest { diff --git a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/NotifySoftReferenceParserTest.php b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/NotifySoftReferenceParserTest.php index fd82cf075804..9b41530d03ca 100644 --- a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/NotifySoftReferenceParserTest.php +++ b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/NotifySoftReferenceParserTest.php @@ -15,9 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace Unit\DataHandling\SoftReference; - -use TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference\AbstractSoftReferenceParserTest; +namespace TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference; class NotifySoftReferenceParserTest extends AbstractSoftReferenceParserTest { diff --git a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/SubstituteSoftReferenceParserTest.php b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/SubstituteSoftReferenceParserTest.php index d46df8bb809f..4a2456d58e11 100644 --- a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/SubstituteSoftReferenceParserTest.php +++ b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/SubstituteSoftReferenceParserTest.php @@ -15,9 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace Unit\DataHandling\SoftReference; - -use TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference\AbstractSoftReferenceParserTest; +namespace TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference; class SubstituteSoftReferenceParserTest extends AbstractSoftReferenceParserTest { diff --git a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/TypoLinkSoftReferenceParserTest.php b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/TypoLinkSoftReferenceParserTest.php index be7fecb5de6a..5922eb441698 100644 --- a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/TypoLinkSoftReferenceParserTest.php +++ b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/TypoLinkSoftReferenceParserTest.php @@ -15,12 +15,11 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace Unit\DataHandling\SoftReference; +namespace TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference; use TYPO3\CMS\Core\Resource\File; use TYPO3\CMS\Core\Resource\Folder; use TYPO3\CMS\Core\Resource\ResourceFactory; -use TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference\AbstractSoftReferenceParserTest; use TYPO3\CMS\Core\Utility\GeneralUtility; class TypoLinkSoftReferenceParserTest extends AbstractSoftReferenceParserTest diff --git a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/TypoLinkTagSoftReferenceParserTest.php b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/TypoLinkTagSoftReferenceParserTest.php index 0174bcad5a6d..f16fa377ce95 100644 --- a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/TypoLinkTagSoftReferenceParserTest.php +++ b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/TypoLinkTagSoftReferenceParserTest.php @@ -15,12 +15,11 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace Unit\DataHandling\SoftReference; +namespace TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference; use TYPO3\CMS\Core\Resource\File; use TYPO3\CMS\Core\Resource\Folder; use TYPO3\CMS\Core\Resource\ResourceFactory; -use TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference\AbstractSoftReferenceParserTest; use TYPO3\CMS\Core\Utility\GeneralUtility; class TypoLinkTagSoftReferenceParserTest extends AbstractSoftReferenceParserTest diff --git a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/UrlSoftReferenceParserTest.php b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/UrlSoftReferenceParserTest.php index f44cc347166d..56f3a168a2be 100644 --- a/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/UrlSoftReferenceParserTest.php +++ b/typo3/sysext/core/Tests/Unit/DataHandling/SoftReference/UrlSoftReferenceParserTest.php @@ -15,9 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace Unit\DataHandling\SoftReference; - -use TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference\AbstractSoftReferenceParserTest; +namespace TYPO3\CMS\Core\Tests\Unit\DataHandling\SoftReference; class UrlSoftReferenceParserTest extends AbstractSoftReferenceParserTest { -- GitLab