From b09fb1047fa57162b04b0b8145eafa452e8d74bb Mon Sep 17 00:00:00 2001 From: Art4 Date: Sun, 15 Dec 2024 21:28:34 +0000 Subject: [PATCH] Rename AbstractLoggerTest to LoggerTestCase --- tests/{src/Core/Logger => }/LoggerDataTrait.php | 2 +- .../Core/Logger/AbstractLoggerTest.php => LoggerTestCase.php} | 4 ++-- tests/src/Core/Logger/ProfilerLoggerTest.php | 1 + tests/src/Core/Logger/StreamLoggerTest.php | 3 ++- tests/src/Core/Logger/SyslogLoggerTest.php | 3 ++- 5 files changed, 8 insertions(+), 5 deletions(-) rename tests/{src/Core/Logger => }/LoggerDataTrait.php (96%) rename tests/{src/Core/Logger/AbstractLoggerTest.php => LoggerTestCase.php} (97%) diff --git a/tests/src/Core/Logger/LoggerDataTrait.php b/tests/LoggerDataTrait.php similarity index 96% rename from tests/src/Core/Logger/LoggerDataTrait.php rename to tests/LoggerDataTrait.php index dd41bf890d..229a1997ea 100644 --- a/tests/src/Core/Logger/LoggerDataTrait.php +++ b/tests/LoggerDataTrait.php @@ -5,7 +5,7 @@ // // SPDX-License-Identifier: AGPL-3.0-or-later -namespace Friendica\Test\src\Core\Logger; +namespace Friendica\Test; trait LoggerDataTrait { diff --git a/tests/src/Core/Logger/AbstractLoggerTest.php b/tests/LoggerTestCase.php similarity index 97% rename from tests/src/Core/Logger/AbstractLoggerTest.php rename to tests/LoggerTestCase.php index b1a793d41f..a31ba5d6a9 100644 --- a/tests/src/Core/Logger/AbstractLoggerTest.php +++ b/tests/LoggerTestCase.php @@ -5,7 +5,7 @@ // // SPDX-License-Identifier: AGPL-3.0-or-later -namespace Friendica\Test\src\Core\Logger; +namespace Friendica\Test; use Friendica\Core\Config\Capability\IManageConfigValues; use Friendica\Core\Logger\Util\Introspection; @@ -14,7 +14,7 @@ use Mockery\MockInterface; use Psr\Log\LoggerInterface; use Psr\Log\LogLevel; -abstract class AbstractLoggerTest extends MockedTestCase +abstract class LoggerTestCase extends MockedTestCase { use LoggerDataTrait; diff --git a/tests/src/Core/Logger/ProfilerLoggerTest.php b/tests/src/Core/Logger/ProfilerLoggerTest.php index 9ae1d5b3ef..f137e8c7fa 100644 --- a/tests/src/Core/Logger/ProfilerLoggerTest.php +++ b/tests/src/Core/Logger/ProfilerLoggerTest.php @@ -8,6 +8,7 @@ namespace Friendica\Test\src\Core\Logger; use Friendica\Core\Logger\Type\ProfilerLogger; +use Friendica\Test\LoggerDataTrait; use Friendica\Test\MockedTestCase; use Friendica\Util\Profiler; use Mockery\MockInterface; diff --git a/tests/src/Core/Logger/StreamLoggerTest.php b/tests/src/Core/Logger/StreamLoggerTest.php index 9fbb6b631e..5d6dc84c44 100644 --- a/tests/src/Core/Logger/StreamLoggerTest.php +++ b/tests/src/Core/Logger/StreamLoggerTest.php @@ -9,13 +9,14 @@ namespace Friendica\Test\src\Core\Logger; use Friendica\Core\Logger\Exception\LoggerArgumentException; use Friendica\Core\Logger\Exception\LogLevelException; +use Friendica\Test\LoggerTestCase; use Friendica\Test\Util\VFSTrait; use Friendica\Core\Logger\Type\StreamLogger; use org\bovigo\vfs\vfsStream; use org\bovigo\vfs\vfsStreamFile; use Psr\Log\LogLevel; -class StreamLoggerTest extends AbstractLoggerTest +class StreamLoggerTest extends LoggerTestCase { use VFSTrait; diff --git a/tests/src/Core/Logger/SyslogLoggerTest.php b/tests/src/Core/Logger/SyslogLoggerTest.php index ca3267e165..ecdaf19e27 100644 --- a/tests/src/Core/Logger/SyslogLoggerTest.php +++ b/tests/src/Core/Logger/SyslogLoggerTest.php @@ -9,9 +9,10 @@ namespace Friendica\Test\src\Core\Logger; use Friendica\Core\Logger\Exception\LogLevelException; use Friendica\Core\Logger\Type\SyslogLogger; +use Friendica\Test\LoggerTestCase; use Psr\Log\LogLevel; -class SyslogLoggerTest extends AbstractLoggerTest +class SyslogLoggerTest extends LoggerTestCase { /** * @var SyslogLoggerWrapper