Ignore:
Timestamp:
Jun 3, 2006 7:47:48 PM (18 years ago)
Author:
scdev
Message:

Q - Merged branches/2.0singleton into trunk. Completed updating classes to use singleton methods. Implemented tests. Fixed some bugs. Changed some interfaces.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/Auth_FileTest.php

    r42 r136  
    2323        require dirname(__FILE__) . '/_config.inc.php';
    2424        require_once '../lib/Auth_File.inc.php';
    25         $this->Auth_File =& new Auth_File(array('htpasswd_file' => dirname(__FILE__) . '/_test_htpasswd'));
     25        $this->Auth_File =& new Auth_File('test_auth');
     26        $this->Auth_File->setParam(array('htpasswd_file' => dirname(__FILE__) . '/_test_htpasswd'));
    2627    }
    2728
     
    4445        $result = $this->Auth_File->login('testuser', 'testpass');
    4546        $this->assertTrue($result, 'testuser login failed.');
    46         $this->assertTrue($_SESSION['_auth']['authenticated'], 'testuser authentication not found in session.');
     47        $this->assertTrue($_SESSION[$this->Auth_File->_ns]['authenticated'], 'testuser authentication not found in session.');
    4748    }
    4849
     
    5152        $result = $this->Auth_File->login('testuser', 'testpass');
    5253        $this->Auth_File->clearauth();
    53         $this->assertFalse($_SESSION['_auth']['authenticated'], 'testuser authentication not false in session.');
     54        $this->assertFalse($_SESSION[$this->Auth_File->_ns]['authenticated'], 'testuser authentication not false in session.');
    5455    }
    5556
Note: See TracChangeset for help on using the changeset viewer.