Dev: Fixed flaky OIDC test, updated dev version

This commit is contained in:
Dan Brown 2024-03-12 12:08:26 +00:00
parent 2ed931aeed
commit 07761524af
No known key found for this signature in database
GPG Key ID: 46D9F943C24A2EF9
2 changed files with 9 additions and 3 deletions

View File

@ -594,10 +594,16 @@ class OidcTest extends TestCase
{
config()->set(['oidc.end_session_endpoint' => 'https://example.com/logout']);
$this->runLogin();
// Fix times so our token is predictable
$claimOverrides = [
'iat' => time(),
'exp' => time() + 720,
'auth_time' => time()
];
$this->runLogin($claimOverrides);
$resp = $this->asEditor()->post('/oidc/logout');
$query = 'id_token_hint=' . urlencode(OidcJwtHelper::idToken()) . '&post_logout_redirect_uri=' . urlencode(url('/'));
$query = 'id_token_hint=' . urlencode(OidcJwtHelper::idToken($claimOverrides)) . '&post_logout_redirect_uri=' . urlencode(url('/'));
$resp->assertRedirect('https://example.com/logout?' . $query);
}

View File

@ -1 +1 @@
v23.09-dev
v24.03-dev