diff --git a/tests/framework/web/session/SessionTest.php b/tests/framework/web/session/SessionTest.php index 7dfe1f17d9..78c84f3ba5 100644 --- a/tests/framework/web/session/SessionTest.php +++ b/tests/framework/web/session/SessionTest.php @@ -47,8 +47,13 @@ class SessionTest extends TestCase $oldUseTransparentSession = $session->getUseTransparentSessionID(); $session->setUseTransparentSessionID(true); $newUseTransparentSession = $session->getUseTransparentSessionID(); - $this->assertNotEquals($oldUseTransparentSession, $newUseTransparentSession); - $this->assertTrue($newUseTransparentSession); + if (PHP_VERSION_ID < 80400) { + $this->assertNotEquals($oldUseTransparentSession, $newUseTransparentSession); + $this->assertTrue($newUseTransparentSession); + } else { + $this->assertEquals($oldUseTransparentSession, $newUseTransparentSession); + $this->assertFalse($newUseTransparentSession); + } //without this line phpunit will complain about risky tests due to unclosed buffer $session->setUseTransparentSessionID(false);