Skip to content

Commit 647f531

Browse files
Use psr/log/LoggerAwareTrait. (#116)
* Use psr/log/LoggerAwareTrait.
1 parent deb69d4 commit 647f531

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

tests/ConnectionTest.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
namespace Yiisoft\Db\Sqlite\Tests;
66

77
use PDO;
8+
use Psr\Log\NullLogger;
89
use Yiisoft\Cache\CacheKeyNormalizer;
910
use Yiisoft\Db\Connection\ConnectionInterface;
1011
use Yiisoft\Db\Exception\Exception;
@@ -42,7 +43,7 @@ public function testExceptionContainsRawQuery(): void
4243
$this->runExceptionTest($db);
4344

4445
/* profiling only */
45-
$db->setLogger(null);
46+
$db->setLogger(new NullLogger());
4647
$db->setProfiler($this->profiler);
4748
$this->runExceptionTest($db);
4849

@@ -52,7 +53,7 @@ public function testExceptionContainsRawQuery(): void
5253
$this->runExceptionTest($db);
5354

5455
/* disabled */
55-
$db->setLogger(null);
56+
$db->setLogger(new NullLogger());
5657
$db->setProfiler(null);
5758
$this->runExceptionTest($db);
5859
}

0 commit comments

Comments
 (0)