File tree 1 file changed +4
-9
lines changed 1 file changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -224,9 +224,6 @@ public function testSetContentJsonSerializeError()
224
224
{
225
225
$ this ->expectException (\Exception::class);
226
226
$ this ->expectExceptionMessage ('This error is expected ' );
227
- if (!interface_exists (\JsonSerializable::class, false )) {
228
- $ this ->markTestSkipped ('JsonSerializable is required. ' );
229
- }
230
227
231
228
$ serializable = new JsonSerializableObject ();
232
229
@@ -280,12 +277,10 @@ public function testConstructorWithObjectWithoutToStringMethodThrowsAnException(
280
277
}
281
278
}
282
279
283
- if (interface_exists (\JsonSerializable::class, false )) {
284
- class JsonSerializableObject implements \JsonSerializable
280
+ class JsonSerializableObject implements \JsonSerializable
281
+ {
282
+ public function jsonSerialize (): array
285
283
{
286
- public function jsonSerialize ()
287
- {
288
- throw new \Exception ('This error is expected ' );
289
- }
284
+ throw new \Exception ('This error is expected ' );
290
285
}
291
286
}
You can’t perform that action at this time.
0 commit comments