Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix test with symfony/config:^7.2 #495

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion Tests/DependencyInjection/ConfigurationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@

namespace Symfony\Bundle\MonologBundle\Tests\DependencyInjection;

use Composer\InstalledVersions;
use Monolog\Logger;
use PHPUnit\Framework\TestCase;
use Symfony\Bundle\MonologBundle\DependencyInjection\Configuration;
Expand Down Expand Up @@ -534,7 +535,13 @@ public function testWithProcessPsr3Messages(array $configuration, array $process
public function processPsr3MessagesProvider(): iterable
{
yield 'Not specified' => [[], ['enabled' => null]];
yield 'Null' => [['process_psr_3_messages' => null], ['enabled' => true]];

if (version_compare(InstalledVersions::getVersion('symfony/config'), '7.2', '>=')) {
yield 'Null' => [['process_psr_3_messages' => null], ['enabled' => null]];
} else {
yield 'Null' => [['process_psr_3_messages' => null], ['enabled' => true]];
}

yield 'True' => [['process_psr_3_messages' => true], ['enabled' => true]];
yield 'False' => [['process_psr_3_messages' => false], ['enabled' => false]];

Expand Down
Loading