Skip to content

Commit

Permalink
Migrating SessionHelperTest to phpunit
Browse files Browse the repository at this point in the history
  • Loading branch information
lorenzo committed Jun 5, 2010
1 parent 94dd8a2 commit 7aa01c4
Showing 1 changed file with 2 additions and 20 deletions.
22 changes: 2 additions & 20 deletions cake/tests/cases/libs/view/helpers/session.test.php
Expand Up @@ -37,7 +37,7 @@ class SessionHelperTest extends CakeTestCase {
* @access public
* @return void
*/
function startTest() {
function setUp() {
$this->Session = new SessionHelper();

$_SESSION = array(
Expand Down Expand Up @@ -77,27 +77,9 @@ function startTest() {
function tearDown() {
$_SESSION = array();
unset($this->Session);
}

/**
* endTest
*
* @access public
* @return void
*/
function endTest() {
App::build();
}

/**
* test construction and initial property settings
*
* @return void
*/
function testConstruct() {
$this->assertFalse(empty($this->Session->sessionTime));
$this->assertFalse(empty($this->Session->security));
}
/**
* testRead method
*
Expand Down Expand Up @@ -220,7 +202,7 @@ function testDisabling() {
$this->assertFalse($this->Session->flash('bare'));
$result = ob_get_contents();
ob_clean();
$this->assertFalse($result);
$this->assertEquals($result, '');
}

/**
Expand Down

0 comments on commit 7aa01c4

Please sign in to comment.