1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-08-07 13:46:38 +02:00

Fix phpunit deprecations

This commit is contained in:
Jordi Boggiano
2024-04-12 17:26:33 +02:00
parent 5b990255a3
commit b127292ee0
39 changed files with 220 additions and 302 deletions

View File

@@ -15,6 +15,7 @@ use DateTimeZone;
use Monolog\Handler\TestHandler;
use Monolog\Formatter\LineFormatter;
use Monolog\Processor\PsrLogMessageProcessor;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\MockObject\MockObject;
use PHPUnit\Framework\TestCase;
use Psr\Log\InvalidArgumentException;
@@ -63,9 +64,7 @@ class PsrLogCompatTest extends TestCase
$this->assertInstanceOf(LoggerInterface::class, $this->getLogger());
}
/**
* @dataProvider provideLevelsAndMessages
*/
#[DataProvider('provideLevelsAndMessages')]
public function testLogsAtAllLevels($level, $message)
{
$logger = $this->getLogger();
@@ -170,7 +169,7 @@ class PsrLogCompatTest extends TestCase
->getMock();
$mock->method('__toString')
->will($this->returnValue($string));
->willReturn($string);
return $mock;
}