@@ -236,10 +236,10 @@ public function assertJsonFragment(array $data)
236236
237237 PHPUnit::assertTrue (
238238 Str::contains ($ actual , $ expected ),
239- 'Unable to find JSON fragment: ' . PHP_EOL . PHP_EOL .
240- '[ ' . json_encode ([$ key => $ value ]) . '] ' . PHP_EOL . PHP_EOL .
241- 'within ' . PHP_EOL . PHP_EOL .
242- "[ {$ actual }]. "
239+ 'Unable to find JSON fragment: ' . PHP_EOL . PHP_EOL
240+ . '[ ' . json_encode ([$ key => $ value ]) . '] ' . PHP_EOL . PHP_EOL
241+ . 'within ' . PHP_EOL . PHP_EOL
242+ . "[ {$ actual }]. "
243243 );
244244 }
245245
@@ -267,10 +267,10 @@ public function assertJsonMissing(array $data, $exact = false)
267267
268268 PHPUnit::assertFalse (
269269 Str::contains ($ actual , $ unexpected ),
270- 'Found unexpected JSON fragment: ' . PHP_EOL . PHP_EOL .
271- '[ ' . json_encode ([$ key => $ value ]) . '] ' . PHP_EOL . PHP_EOL .
272- 'within ' . PHP_EOL . PHP_EOL .
273- "[ {$ actual }]. "
270+ 'Found unexpected JSON fragment: ' . PHP_EOL . PHP_EOL
271+ . '[ ' . json_encode ([$ key => $ value ]) . '] ' . PHP_EOL . PHP_EOL
272+ . 'within ' . PHP_EOL . PHP_EOL
273+ . "[ {$ actual }]. "
274274 );
275275 }
276276
@@ -297,10 +297,10 @@ public function assertJsonMissingExact(array $data)
297297 }
298298
299299 PHPUnit::fail (
300- 'Found unexpected JSON fragment: ' . PHP_EOL . PHP_EOL .
301- '[ ' . json_encode ($ data ) . '] ' . PHP_EOL . PHP_EOL .
302- 'within ' . PHP_EOL . PHP_EOL .
303- "[ {$ actual }]. "
300+ 'Found unexpected JSON fragment: ' . PHP_EOL . PHP_EOL
301+ . '[ ' . json_encode ($ data ) . '] ' . PHP_EOL . PHP_EOL
302+ . 'within ' . PHP_EOL . PHP_EOL
303+ . "[ {$ actual }]. "
304304 );
305305 }
306306
@@ -381,8 +381,8 @@ public function assertJsonValidationErrors($keys)
381381 $ errors = $ this ->json ()['errors ' ] ?? [];
382382
383383 $ errorMessage = $ errors
384- ? 'Response has the following JSON validation errors: ' .
385- PHP_EOL . PHP_EOL . json_encode ($ errors , JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE ) . PHP_EOL
384+ ? 'Response has the following JSON validation errors: '
385+ . PHP_EOL . PHP_EOL . json_encode ($ errors , JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE ) . PHP_EOL
386386 : 'Response does not have JSON validation errors. ' ;
387387
388388 foreach ($ keys as $ key ) {
@@ -416,8 +416,8 @@ public function assertJsonMissingValidationErrors($keys = null)
416416
417417 if (is_null ($ keys ) && count ($ errors ) > 0 ) {
418418 PHPUnit::fail (
419- 'Response has unexpected validation errors: ' . PHP_EOL . PHP_EOL .
420- json_encode ($ errors , JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE )
419+ 'Response has unexpected validation errors: ' . PHP_EOL . PHP_EOL
420+ . json_encode ($ errors , JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE )
421421 );
422422 }
423423
@@ -489,10 +489,10 @@ protected function assertJsonMessage(array $data)
489489
490490 $ actual = json_encode ($ this ->decodeResponseJson (), JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES );
491491
492- return 'Unable to find JSON: ' . PHP_EOL . PHP_EOL .
493- "[ {$ expected }] " . PHP_EOL . PHP_EOL .
494- 'within response JSON: ' . PHP_EOL . PHP_EOL .
495- "[ {$ actual }]. " . PHP_EOL . PHP_EOL ;
492+ return 'Unable to find JSON: ' . PHP_EOL . PHP_EOL
493+ . "[ {$ expected }] " . PHP_EOL . PHP_EOL
494+ . 'within response JSON: ' . PHP_EOL . PHP_EOL
495+ . "[ {$ actual }]. " . PHP_EOL . PHP_EOL ;
496496 }
497497
498498 /**
0 commit comments