From af0dab0e1b121a638005fad4f7995934d39aaf4a Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Tue, 31 Oct 2023 11:35:54 +0900 Subject: [PATCH] Always initialize Context before unit test --- tests/_bootstrap.php | 1 + tests/unit/framework/PasswordTest.php | 5 ----- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/tests/_bootstrap.php b/tests/_bootstrap.php index 89f33a650..88ecda948 100644 --- a/tests/_bootstrap.php +++ b/tests/_bootstrap.php @@ -12,6 +12,7 @@ $_SERVER['REQUEST_URI'] = '/' . basename(dirname(__DIR__)) . '/index.php'; // Include the autoloader. require_once dirname(__DIR__) . '/common/autoload.php'; +Context::init(); function _debug() { $args = func_get_args(); diff --git a/tests/unit/framework/PasswordTest.php b/tests/unit/framework/PasswordTest.php index 4976f3a3e..c00c81aca 100644 --- a/tests/unit/framework/PasswordTest.php +++ b/tests/unit/framework/PasswordTest.php @@ -2,11 +2,6 @@ class PasswordTest extends \Codeception\Test\Unit { - public function _before() - { - \Context::init(); - } - public function testIsValidAlgorithm() { $this->assertTrue(Rhymix\Framework\Password::isValidAlgorithm('bcrypt'));