mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-03-18 15:39:53 +00:00
Remvoed session destruction from tests.
This commit is contained in:
parent
a78bb20bda
commit
ca1c8f1f80
1 changed files with 0 additions and 6 deletions
|
@ -349,8 +349,6 @@ class SessionComponentTest extends CakeTestCase {
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
function testSessionTimeout() {
|
function testSessionTimeout() {
|
||||||
|
|
||||||
session_destroy();
|
|
||||||
Configure::write('Security.level', 'low');
|
Configure::write('Security.level', 'low');
|
||||||
$Session =& new SessionComponent();
|
$Session =& new SessionComponent();
|
||||||
$Session->write('Test', 'some value');
|
$Session->write('Test', 'some value');
|
||||||
|
@ -361,7 +359,6 @@ class SessionComponentTest extends CakeTestCase {
|
||||||
$this->assertEqual($Session->time, mktime());
|
$this->assertEqual($Session->time, mktime());
|
||||||
$this->assertEqual($_SESSION['Config']['time'], $Session->time + (Security::inactiveMins() * Configure::read('Session.timeout')));
|
$this->assertEqual($_SESSION['Config']['time'], $Session->time + (Security::inactiveMins() * Configure::read('Session.timeout')));
|
||||||
|
|
||||||
session_destroy();
|
|
||||||
Configure::write('Security.level', 'medium');
|
Configure::write('Security.level', 'medium');
|
||||||
$Session =& new SessionComponent();
|
$Session =& new SessionComponent();
|
||||||
$Session->write('Test', 'some value');
|
$Session->write('Test', 'some value');
|
||||||
|
@ -371,8 +368,6 @@ class SessionComponentTest extends CakeTestCase {
|
||||||
$this->assertEqual($Session->time, mktime());
|
$this->assertEqual($Session->time, mktime());
|
||||||
$this->assertEqual($_SESSION['Config']['time'], $Session->time + (Security::inactiveMins() * Configure::read('Session.timeout')));
|
$this->assertEqual($_SESSION['Config']['time'], $Session->time + (Security::inactiveMins() * Configure::read('Session.timeout')));
|
||||||
|
|
||||||
|
|
||||||
session_destroy();
|
|
||||||
Configure::write('Security.level', 'high');
|
Configure::write('Security.level', 'high');
|
||||||
$Session =& new SessionComponent();
|
$Session =& new SessionComponent();
|
||||||
$Session->write('Test', 'some value');
|
$Session->write('Test', 'some value');
|
||||||
|
@ -381,6 +376,5 @@ class SessionComponentTest extends CakeTestCase {
|
||||||
$this->assertEqual($_SESSION['Config']['time'], $Session->sessionTime);
|
$this->assertEqual($_SESSION['Config']['time'], $Session->sessionTime);
|
||||||
$this->assertEqual($Session->time, mktime());
|
$this->assertEqual($Session->time, mktime());
|
||||||
$this->assertEqual($_SESSION['Config']['time'], $Session->time + (Security::inactiveMins() * Configure::read('Session.timeout')));
|
$this->assertEqual($_SESSION['Config']['time'], $Session->time + (Security::inactiveMins() * Configure::read('Session.timeout')));
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue