mirror of
https://github.com/linuxserver/Heimdall.git
synced 2025-12-06 06:53:55 +09:00
update to laravel 5.7 and try getting autologin saved
This commit is contained in:
@@ -1,38 +0,0 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* This file is part of the Symfony package.
|
||||
*
|
||||
* (c) Fabien Potencier <fabien@symfony.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Symfony\Component\HttpFoundation\Tests\Session\Storage\Proxy;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use Symfony\Component\HttpFoundation\Session\Storage\Proxy\NativeProxy;
|
||||
|
||||
/**
|
||||
* Test class for NativeProxy.
|
||||
*
|
||||
* @group legacy
|
||||
*
|
||||
* @author Drak <drak@zikula.org>
|
||||
*/
|
||||
class NativeProxyTest extends TestCase
|
||||
{
|
||||
public function testIsWrapper()
|
||||
{
|
||||
$proxy = new NativeProxy();
|
||||
$this->assertFalse($proxy->isWrapper());
|
||||
}
|
||||
|
||||
public function testGetSaveHandlerName()
|
||||
{
|
||||
$name = ini_get('session.save_handler');
|
||||
$proxy = new NativeProxy();
|
||||
$this->assertEquals($name, $proxy->getSaveHandlerName());
|
||||
}
|
||||
}
|
||||
@@ -121,4 +121,37 @@ class SessionHandlerProxyTest extends TestCase
|
||||
|
||||
$this->proxy->gc(86400);
|
||||
}
|
||||
|
||||
/**
|
||||
* @requires PHPUnit 5.1
|
||||
*/
|
||||
public function testValidateId()
|
||||
{
|
||||
$mock = $this->getMockBuilder(array('SessionHandlerInterface', 'SessionUpdateTimestampHandlerInterface'))->getMock();
|
||||
$mock->expects($this->once())
|
||||
->method('validateId');
|
||||
|
||||
$proxy = new SessionHandlerProxy($mock);
|
||||
$proxy->validateId('id');
|
||||
|
||||
$this->assertTrue($this->proxy->validateId('id'));
|
||||
}
|
||||
|
||||
/**
|
||||
* @requires PHPUnit 5.1
|
||||
*/
|
||||
public function testUpdateTimestamp()
|
||||
{
|
||||
$mock = $this->getMockBuilder(array('SessionHandlerInterface', 'SessionUpdateTimestampHandlerInterface'))->getMock();
|
||||
$mock->expects($this->once())
|
||||
->method('updateTimestamp');
|
||||
|
||||
$proxy = new SessionHandlerProxy($mock);
|
||||
$proxy->updateTimestamp('id', 'data');
|
||||
|
||||
$this->mock->expects($this->once())
|
||||
->method('write');
|
||||
|
||||
$this->proxy->updateTimestamp('id', 'data');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user