8000 Merge branch '4.4' into 5.2 · symfony/http-foundation@9e5b33c · GitHub
[go: up one dir, main page]

Skip to content

Commit 9e5b33c

Browse files
committed
Merge branch '4.4' into 5.2
* 4.4: Fix incompatible implicit float-to-int conversions [Translation] Don't pass null to strtoupper() cs fix [DependencyInjection] Don't pass null to trim() Add return types to JsonSerializable implementations Fix Serializable deprecations triggered by token mocks Add missing security translations
2 parents 7ca2875 + 89c7cca commit 9e5b33c

File tree

1 file changed

+4
-9
lines changed

1 file changed

+4
-9
lines changed

Tests/JsonResponseTest.php

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -251,9 +251,6 @@ public function testSetContentJsonSerializeError()
251251
{
252252
$this->expectException(\Exception::class);
253253
$this->expectExceptionMessage('This error is expected');
254-
if (!interface_exists(\JsonSerializable::class, false)) {
255-
$this->markTestSkipped('JsonSerializable is required.');
256-
}
257254

258255
$serializable = new JsonSerializableObject();
259256

@@ -299,12 +296,10 @@ public function testConstructorWithObjectWithoutToStringMethodThrowsAnException(
299296
}
300297
}
301298

302-
if (interface_exists(\JsonSerializable::class, false)) {
303-
class JsonSerializableObject implements \JsonSerializable
299+
class JsonSerializableObject implements \JsonSerializable
300+
{
301+
public function jsonSerialize(): array
304302
{
305-
public function jsonSerialize()
306-
{
307-
throw new \Exception('This error is expected');
308-
}
303+
throw new \Exception('This error is expected');
309304
}
310305
}

0 commit comments

Comments
 (0)
0