public function MockFileSessionStorageTest::testMultipleInstances in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/symfony/http-foundation/Tests/Session/Storage/MockFileSessionStorageTest.php \Symfony\Component\HttpFoundation\Tests\Session\Storage\MockFileSessionStorageTest::testMultipleInstances()
File
- vendor/
symfony/ http-foundation/ Tests/ Session/ Storage/ MockFileSessionStorageTest.php, line 96
Class
- MockFileSessionStorageTest
- Test class for MockFileSessionStorage.
Namespace
Symfony\Component\HttpFoundation\Tests\Session\StorageCode
public function testMultipleInstances() {
$storage1 = $this
->getStorage();
$storage1
->start();
$storage1
->getBag('attributes')
->set('foo', 'bar');
$storage1
->save();
$storage2 = $this
->getStorage();
$storage2
->setId($storage1
->getId());
$storage2
->start();
$this
->assertEquals('bar', $storage2
->getBag('attributes')
->get('foo'), 'values persist between instances');
}