public function NativeSessionStorageTest::testSetSaveHandler54 in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/http-foundation/Tests/Session/Storage/NativeSessionStorageTest.php \Symfony\Component\HttpFoundation\Tests\Session\Storage\NativeSessionStorageTest::testSetSaveHandler54()
File
- vendor/
symfony/ http-foundation/ Tests/ Session/ Storage/ NativeSessionStorageTest.php, line 201
Class
- NativeSessionStorageTest
- Test class for NativeSessionStorage.
Namespace
Symfony\Component\HttpFoundation\Tests\Session\StorageCode
public function testSetSaveHandler54() {
if (PHP_VERSION_ID < 50400) {
$this
->markTestSkipped('Test skipped, for PHP 5.4 only.');
}
$this
->iniSet('session.save_handler', 'files');
$storage = $this
->getStorage();
$storage
->setSaveHandler();
$this
->assertInstanceOf('Symfony\\Component\\HttpFoundation\\Session\\Storage\\Proxy\\SessionHandlerProxy', $storage
->getSaveHandler());
$storage
->setSaveHandler(null);
$this
->assertInstanceOf('Symfony\\Component\\HttpFoundation\\Session\\Storage\\Proxy\\SessionHandlerProxy', $storage
->getSaveHandler());
$storage
->setSaveHandler(new SessionHandlerProxy(new NativeSessionHandler()));
$this
->assertInstanceOf('Symfony\\Component\\HttpFoundation\\Session\\Storage\\Proxy\\SessionHandlerProxy', $storage
->getSaveHandler());
$storage
->setSaveHandler(new NativeSessionHandler());
$this
->assertInstanceOf('Symfony\\Component\\HttpFoundation\\Session\\Storage\\Proxy\\SessionHandlerProxy', $storage
->getSaveHandler());
$storage
->setSaveHandler(new SessionHandlerProxy(new NullSessionHandler()));
$this
->assertInstanceOf('Symfony\\Component\\HttpFoundation\\Session\\Storage\\Proxy\\SessionHandlerProxy', $storage
->getSaveHandler());
$storage
->setSaveHandler(new NullSessionHandler());
$this
->assertInstanceOf('Symfony\\Component\\HttpFoundation\\Session\\Storage\\Proxy\\SessionHandlerProxy', $storage
->getSaveHandler());
}