diff --git a/tests/Integration/features/bootstrap/FeatureContext.php b/tests/Integration/features/bootstrap/FeatureContext.php index 6e8749b73..bcbe553d5 100644 --- a/tests/Integration/features/bootstrap/FeatureContext.php +++ b/tests/Integration/features/bootstrap/FeatureContext.php @@ -1782,7 +1782,12 @@ private function getUserRequestToken(string $user): void { $client = new Client($this->clientOptions); $response = $client->get( $loginUrl, - ['cookies' => $this->cookieJars[$user]] + [ + 'cookies' => $this->cookieJars[$user], + 'headers' => [ + 'Origin' => $this->baseUrl, + ], + ], ); $requestToken = substr(preg_replace('/(.*)data-requesttoken="(.*)">(.*)/sm', '\2', $response->getBody()->getContents()), 0, 89); @@ -1797,6 +1802,9 @@ private function getUserRequestToken(string $user): void { 'requesttoken' => $requestToken, ], 'cookies' => $this->cookieJars[$user], + 'headers' => [ + 'Origin' => $this->baseUrl, + ], ] ); $this->assertStatusCode(200);