Loading core/modules/announcements_feed/tests/modules/announce_feed_test/src/AnnounceTestHttpClientMiddleware.php +1 −1 Original line number Diff line number Diff line Loading @@ -20,7 +20,7 @@ public function __invoke(): \Closure { return function ($handler) { return function (RequestInterface $request, array $options) use ($handler): PromiseInterface { $test_end_point = \Drupal::state()->get('announce_test_endpoint'); if ($test_end_point && str_contains($request->getUri(), '://www.drupal.org/announcements.json')) { if ($test_end_point && str_contains((string) $request->getUri(), '://www.drupal.org/announcements.json')) { // Only override $uri if it matches the advisories JSON feed to avoid // changing any other uses of the 'http_client' service during tests with // this module installed. Loading core/modules/block/tests/modules/block_test/src/Controller/TestMultipleFormController.php +1 −1 Original line number Diff line number Diff line Loading @@ -22,7 +22,7 @@ public function testMultipleForms() { // see if there's only one in the tests. $post_render_callable = function ($elements) { $matches = []; preg_match_all('<form\s(.*?)action="(.*?)"(.*)>', $elements, $matches); preg_match_all('<form\s(.*?)action="(.*?)"(.*)>', (string) $elements, $matches); $action_values = $matches[2]; Loading core/modules/system/tests/modules/advisory_feed_test/src/AdvisoryTestClientMiddleware.php +1 −1 Original line number Diff line number Diff line Loading @@ -18,7 +18,7 @@ public function __invoke() { return function ($handler) { return function (RequestInterface $request, array $options) use ($handler): PromiseInterface { $test_end_point = \Drupal::state()->get('advisories_test_endpoint'); if ($test_end_point && str_contains($request->getUri(), '://updates.drupal.org/psa.json')) { if ($test_end_point && str_contains((string) $request->getUri(), '://updates.drupal.org/psa.json')) { // Only override $uri if it matches the advisories JSON feed to avoid // changing any other uses of the 'http_client' service during tests with // this module installed. Loading core/modules/system/tests/modules/csrf_race_test/src/Controller/TestController.php +1 −1 Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ public function testMethod() { * @return \Symfony\Component\HttpFoundation\Response * CSRF token. */ public function getCsrfToken($num) { public function getCsrfToken(int $num) { sleep($num); return new JsonResponse($this->tokenGenerator->get()); } Loading core/modules/system/tests/modules/early_rendering_controller_test/src/EarlyRenderingTestController.php +3 −3 Original line number Diff line number Diff line Loading @@ -94,7 +94,7 @@ public function response() { public function responseEarly() { $render_array = $this->earlyRenderContent(); return new Response($this->renderer->render($render_array)); return new Response((string) $this->renderer->render($render_array)); } public function responseWithAttachments() { Loading @@ -103,7 +103,7 @@ public function responseWithAttachments() { public function responseWithAttachmentsEarly() { $render_array = $this->earlyRenderContent(); return new AttachmentsTestResponse($this->renderer->render($render_array)); return new AttachmentsTestResponse((string) $this->renderer->render($render_array)); } public function cacheableResponse() { Loading @@ -112,7 +112,7 @@ public function cacheableResponse() { public function cacheableResponseEarly() { $render_array = $this->earlyRenderContent(); return new CacheableTestResponse($this->renderer->render($render_array)); return new CacheableTestResponse((string) $this->renderer->render($render_array)); } public function domainObject() { Loading Loading
core/modules/announcements_feed/tests/modules/announce_feed_test/src/AnnounceTestHttpClientMiddleware.php +1 −1 Original line number Diff line number Diff line Loading @@ -20,7 +20,7 @@ public function __invoke(): \Closure { return function ($handler) { return function (RequestInterface $request, array $options) use ($handler): PromiseInterface { $test_end_point = \Drupal::state()->get('announce_test_endpoint'); if ($test_end_point && str_contains($request->getUri(), '://www.drupal.org/announcements.json')) { if ($test_end_point && str_contains((string) $request->getUri(), '://www.drupal.org/announcements.json')) { // Only override $uri if it matches the advisories JSON feed to avoid // changing any other uses of the 'http_client' service during tests with // this module installed. Loading
core/modules/block/tests/modules/block_test/src/Controller/TestMultipleFormController.php +1 −1 Original line number Diff line number Diff line Loading @@ -22,7 +22,7 @@ public function testMultipleForms() { // see if there's only one in the tests. $post_render_callable = function ($elements) { $matches = []; preg_match_all('<form\s(.*?)action="(.*?)"(.*)>', $elements, $matches); preg_match_all('<form\s(.*?)action="(.*?)"(.*)>', (string) $elements, $matches); $action_values = $matches[2]; Loading
core/modules/system/tests/modules/advisory_feed_test/src/AdvisoryTestClientMiddleware.php +1 −1 Original line number Diff line number Diff line Loading @@ -18,7 +18,7 @@ public function __invoke() { return function ($handler) { return function (RequestInterface $request, array $options) use ($handler): PromiseInterface { $test_end_point = \Drupal::state()->get('advisories_test_endpoint'); if ($test_end_point && str_contains($request->getUri(), '://updates.drupal.org/psa.json')) { if ($test_end_point && str_contains((string) $request->getUri(), '://updates.drupal.org/psa.json')) { // Only override $uri if it matches the advisories JSON feed to avoid // changing any other uses of the 'http_client' service during tests with // this module installed. Loading
core/modules/system/tests/modules/csrf_race_test/src/Controller/TestController.php +1 −1 Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ public function testMethod() { * @return \Symfony\Component\HttpFoundation\Response * CSRF token. */ public function getCsrfToken($num) { public function getCsrfToken(int $num) { sleep($num); return new JsonResponse($this->tokenGenerator->get()); } Loading
core/modules/system/tests/modules/early_rendering_controller_test/src/EarlyRenderingTestController.php +3 −3 Original line number Diff line number Diff line Loading @@ -94,7 +94,7 @@ public function response() { public function responseEarly() { $render_array = $this->earlyRenderContent(); return new Response($this->renderer->render($render_array)); return new Response((string) $this->renderer->render($render_array)); } public function responseWithAttachments() { Loading @@ -103,7 +103,7 @@ public function responseWithAttachments() { public function responseWithAttachmentsEarly() { $render_array = $this->earlyRenderContent(); return new AttachmentsTestResponse($this->renderer->render($render_array)); return new AttachmentsTestResponse((string) $this->renderer->render($render_array)); } public function cacheableResponse() { Loading @@ -112,7 +112,7 @@ public function cacheableResponse() { public function cacheableResponseEarly() { $render_array = $this->earlyRenderContent(); return new CacheableTestResponse($this->renderer->render($render_array)); return new CacheableTestResponse((string) $this->renderer->render($render_array)); } public function domainObject() { Loading