Skip to content

Commit ee200f9

Browse files
authored
[9.x] Fix Symfony 7.4 integrations (#375)
Signed-off-by: Mior Muhammad Zaki <crynobone@gmail.com>
1 parent 2cede99 commit ee200f9

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
"require": {
3939
"php": "^8.2",
4040
"composer-runtime-api": "^2.2",
41-
"orchestra/sidekick": "~1.1.20|~1.2.17",
41+
"orchestra/sidekick": "~1.1.21|~1.2.18",
4242
"symfony/deprecation-contracts": "^2.5|^3.0",
4343
"symfony/polyfill-php83": "^1.32"
4444
},

tests/Workbench/DiscoversTest.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111
use PHPUnit\Framework\Attributes\Test;
1212
use PHPUnit\Framework\Attributes\TestWith;
1313

14+
use function Orchestra\Sidekick\package_version_compare;
15+
1416
#[WithConfig('app.key', 'AckfSECXIvnK5r28GVIWUAxmbBSjTsmF')]
1517
class DiscoversTest extends TestCase
1618
{
@@ -38,10 +40,14 @@ public function it_can_resolve_web_routes_from_discovers()
3840
#[Test]
3941
public function it_can_resolve_web_routes_using_macro_from_discovers()
4042
{
43+
$contentType = package_version_compare('symfony/http-foundation', '7.4.0', '>=')
44+
? 'text/plain; charset=utf-8'
45+
: 'text/plain; charset=UTF-8';
46+
4147
$this->get('/hello-world')
4248
->assertOk()
4349
->assertSee('Hello world')
44-
->assertHeader('Content-Type', 'text/plain; charset=UTF-8');
50+
->assertHeader('Content-Type', $contentType);
4551
}
4652

4753
#[Test]

0 commit comments

Comments
 (0)