From ed12495ec54853b94a6d93490bf4e2efade2ffa8 Mon Sep 17 00:00:00 2001 From: Eric Espie Date: Tue, 28 Nov 2023 15:16:31 +0100 Subject: [PATCH] =?UTF-8?q?N=C2=B06228=20-=20:white=5Fcheck=5Fmark:=20Fix?= =?UTF-8?q?=20Unit=20tests=20due=20to=20logs=20added=20in=20CRUD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../core/Log/ExceptionLogTest.php | 20 ++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/tests/php-unit-tests/unitary-tests/core/Log/ExceptionLogTest.php b/tests/php-unit-tests/unitary-tests/core/Log/ExceptionLogTest.php index 106e706c7..18a0c65a2 100644 --- a/tests/php-unit-tests/unitary-tests/core/Log/ExceptionLogTest.php +++ b/tests/php-unit-tests/unitary-tests/core/Log/ExceptionLogTest.php @@ -23,6 +23,8 @@ require_once(__DIR__.'/ExceptionLogTest/Exceptions.php'); class ExceptionLogTest extends ItopDataTestCase { + const USE_TRANSACTION = false; + protected function setUp(): void { require_once(__DIR__.'/ExceptionLogTest/Exceptions.php'); @@ -122,13 +124,13 @@ class ExceptionLogTest extends ItopDataTestCase 'logLevelMinWriteInDb' => ['Exception' => 'Debug'], ], 'flat configuration' => [ - 'aLevels' => ['Debug'], + 'aLevels' => ['Error'], 'aExceptions' => [\GrandChildException::class], 'sChannel' => 'GrandChildException', 'aExpectedWriteNumber' => [1], - 'logLevelMin' => 'Debug', + 'logLevelMin' => 'Error', 'iExpectedDbWriteNumber' => [1], - 'logLevelMinWriteInDb' => 'Debug', + 'logLevelMinWriteInDb' => 'Error', ], 'Default conf has expected levels' => [ 'aLevels' => ['Debug', 'Warning'], @@ -203,22 +205,22 @@ class ExceptionLogTest extends ItopDataTestCase 'logLevelMinWriteInDb' => null, ], 'Simple Error (testing Throwable signature)' => [ - 'aLevels' => ['Debug'], + 'aLevels' => ['Error'], 'aExceptions' => [\Error::class], 'sChannel' => 'Error', 'aExpectedWriteNumber' => [1], - 'logLevelMin' => 'Debug', + 'logLevelMin' => 'Error', 'iExpectedDbWriteNumber' => [1], - 'logLevelMinWriteInDb' => 'Debug', + 'logLevelMinWriteInDb' => 'Error', ], "use '' to enable all" => [ - 'aLevels' => ['Debug'], + 'aLevels' => ['Error'], 'aExceptions' => [\GrandChildException::class, \Exception::class], 'sChannel' => 'GrandChildException', 'aExpectedWriteNumber' => [1, 1], - 'logLevelMin' => ['' => 'Debug'], + 'logLevelMin' => ['' => 'Error'], 'iExpectedDbWriteNumber' => [1, 1], - 'logLevelMinWriteInDb' => ['' => 'Debug'], + 'logLevelMinWriteInDb' => ['' => 'Error'], ], ]; }