diff options
author | knut <> | 2007-06-04 23:33:06 +0000 |
---|---|---|
committer | knut <> | 2007-06-04 23:33:06 +0000 |
commit | 996bb8664856b302c96e19c6899010ea72ababe6 (patch) | |
tree | 0daad116697c7c9f58bc74244277457ede412348 /tests/unit/Security | |
parent | b7d5fc392611f0cb7f1ff6d87b758cb9572c7806 (diff) |
added more unit test stubs
Diffstat (limited to 'tests/unit/Security')
-rw-r--r-- | tests/unit/Security/AllTests.php | 35 | ||||
-rw-r--r-- | tests/unit/Security/TAuthManagerTest.php | 67 | ||||
-rw-r--r-- | tests/unit/Security/TAuthorizationRuleTest.php | 51 | ||||
-rw-r--r-- | tests/unit/Security/TSecurityManagerTest.php | 59 | ||||
-rw-r--r-- | tests/unit/Security/TUserManagerTest.php | 55 | ||||
-rw-r--r-- | tests/unit/Security/TUserTest.php | 59 |
6 files changed, 326 insertions, 0 deletions
diff --git a/tests/unit/Security/AllTests.php b/tests/unit/Security/AllTests.php new file mode 100644 index 00000000..7de0996f --- /dev/null +++ b/tests/unit/Security/AllTests.php @@ -0,0 +1,35 @@ +<?php +require_once dirname(__FILE__).'/../phpunit.php'; + +if(!defined('PHPUnit_MAIN_METHOD')) { + define('PHPUnit_MAIN_METHOD', 'Security_AllTests::main'); +} + +require_once 'TAuthManagerTest.php'; +require_once 'TAuthorizationRuleTest.php'; +require_once 'TSecurityManagerTest.php'; +require_once 'TUserManagerTest.php'; +require_once 'TUserTest.php'; + +class Security_AllTests { + public static function main() { + PHPUnit_TextUI_TestRunner::run(self::suite()); + } + + public static function suite() { + $suite = new PHPUnit_Framework_TestSuite('System.Security'); + + $suite->addTestSuite('TAuthManagerTest'); + $suite->addTestSuite('TAuthorizationRuleTest'); + $suite->addTestSuite('TSecurityManagerTest'); + $suite->addTestSuite('TUserManagerTest'); + $suite->addTestSuite('TUserTest'); + + return $suite; + } +} + +if(PHPUnit_MAIN_METHOD == 'Security_AllTests::main') { + Security_AllTests::main(); +} +?> diff --git a/tests/unit/Security/TAuthManagerTest.php b/tests/unit/Security/TAuthManagerTest.php new file mode 100644 index 00000000..6e3c05a9 --- /dev/null +++ b/tests/unit/Security/TAuthManagerTest.php @@ -0,0 +1,67 @@ +<?php +require_once dirname(__FILE__).'/../phpunit.php'; + +Prado::using('System.Security.TAuthManager'); + +/** + * @package System.Security + */ +class TAuthManagerTest extends PHPUnit_Framework_TestCase { + + public function setUp() { + } + + public function tearDown() { + } + + public function testInit() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testUserManager() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testLoginPage() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testDoAuthentication() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testDoAuthorization() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testLeave() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testReturnUrl() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testOnAuthenticate() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testOnAuthorize() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testUpdateSessionUser() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testLogin() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testLogout() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + +} + +?> diff --git a/tests/unit/Security/TAuthorizationRuleTest.php b/tests/unit/Security/TAuthorizationRuleTest.php new file mode 100644 index 00000000..e20542dc --- /dev/null +++ b/tests/unit/Security/TAuthorizationRuleTest.php @@ -0,0 +1,51 @@ +<?php +require_once dirname(__FILE__).'/../phpunit.php'; + +Prado::using('System.Security.TAuthorizationRule'); + +/** + * @package System.Security + */ +class TAuthorizationRuleTest extends PHPUnit_Framework_TestCase { + + public function setUp() { + } + + public function tearDown() { + } + + public function testConstruct() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testAction() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testUsers() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testRoles() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testVerb() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testGuestApplied() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testEveryoneApplied() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testIsUserAllowed() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + +} + +?> diff --git a/tests/unit/Security/TSecurityManagerTest.php b/tests/unit/Security/TSecurityManagerTest.php new file mode 100644 index 00000000..76029bde --- /dev/null +++ b/tests/unit/Security/TSecurityManagerTest.php @@ -0,0 +1,59 @@ +<?php +require_once dirname(__FILE__).'/../phpunit.php'; + +Prado::using('System.Security.TSecurityManager'); + +/** + * @package System.Security + */ +class TSecurityManagerTest extends PHPUnit_Framework_TestCase { + + public function setUp() { + } + + public function tearDown() { + } + + public function testInit() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testValidationKey() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testEncryptionKey() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testValidation() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testEncryption() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testEncrypt() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testDecrypt() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testHashData() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testValidateData() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testComputeHMAC() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + +} + +?> diff --git a/tests/unit/Security/TUserManagerTest.php b/tests/unit/Security/TUserManagerTest.php new file mode 100644 index 00000000..8937ba22 --- /dev/null +++ b/tests/unit/Security/TUserManagerTest.php @@ -0,0 +1,55 @@ +<?php +require_once dirname(__FILE__).'/../phpunit.php'; + +Prado::using('System.Security.TUserManager'); + +/** + * @package System.Security + */ +class TUserManagerTest extends PHPUnit_Framework_TestCase { + + public function setUp() { + } + + public function tearDown() { + } + + public function testInit() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testUsers() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testRoles() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testUserFile() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testGuestName() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testPasswordMode() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testValidateUser() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testUser() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testSwitchToGuest() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + +} + +?> diff --git a/tests/unit/Security/TUserTest.php b/tests/unit/Security/TUserTest.php new file mode 100644 index 00000000..67ac6eb4 --- /dev/null +++ b/tests/unit/Security/TUserTest.php @@ -0,0 +1,59 @@ +<?php +require_once dirname(__FILE__).'/../phpunit.php'; + +Prado::using('System.Security.TUser'); + +/** + * @package System.Security + */ +class TUserTest extends PHPUnit_Framework_TestCase { + + public function setUp() { + } + + public function tearDown() { + } + + public function testConstruct() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testManager() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testName() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testIsGuest() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testRoles() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testIsInRole() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testSaveToString() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testLoadFromString() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testState() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + + public function testStateChanged() { + throw new PHPUnit_Framework_IncompleteTestError(); + } + +} + +?> |