Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
},
"autoload-dev": {
"psr-4": {
"Tests\\": "tests",
"CodeIgniter\\Shield\\Tests\\": "tests",
"Tests\\Support\\": "tests/_support"
}
},
Expand Down
36 changes: 0 additions & 36 deletions phpstan-baseline.php
Original file line number Diff line number Diff line change
Expand Up @@ -187,42 +187,6 @@
'count' => 1,
'path' => __DIR__ . '/src/Models/UserModel.php',
];
$ignoreErrors[] = [
'rawMessage' => 'Call to method setCookie() of internal class CodeIgniter\\Superglobals from outside its root namespace CodeIgniter.',
'identifier' => 'method.internalClass',
'count' => 2,
'path' => __DIR__ . '/tests/Authentication/Authenticators/SessionAuthenticatorTest.php',
];
$ignoreErrors[] = [
'rawMessage' => 'Call to method setServer() of internal class CodeIgniter\\Superglobals from outside its root namespace CodeIgniter.',
'identifier' => 'method.internalClass',
'count' => 2,
'path' => __DIR__ . '/tests/Controllers/ActionsTest.php',
];
$ignoreErrors[] = [
'rawMessage' => 'Call to method unsetServer() of internal class CodeIgniter\\Superglobals from outside its root namespace CodeIgniter.',
'identifier' => 'method.internalClass',
'count' => 1,
'path' => __DIR__ . '/tests/Controllers/ActionsTest.php',
];
$ignoreErrors[] = [
'rawMessage' => 'Call to method setCookie() of internal class CodeIgniter\\Superglobals from outside its root namespace CodeIgniter.',
'identifier' => 'method.internalClass',
'count' => 1,
'path' => __DIR__ . '/tests/Controllers/LoginTest.php',
];
$ignoreErrors[] = [
'rawMessage' => 'Call to method setServer() of internal class CodeIgniter\\Superglobals from outside its root namespace CodeIgniter.',
'identifier' => 'method.internalClass',
'count' => 1,
'path' => __DIR__ . '/tests/Controllers/MagicLinkTest.php',
];
$ignoreErrors[] = [
'rawMessage' => 'Call to method unsetServer() of internal class CodeIgniter\\Superglobals from outside its root namespace CodeIgniter.',
'identifier' => 'method.internalClass',
'count' => 1,
'path' => __DIR__ . '/tests/Controllers/MagicLinkTest.php',
];
$ignoreErrors[] = [
'rawMessage' => 'Call to deprecated method __construct() of class CodeIgniter\\HTTP\\Response:
4.5.0 The param $config is no longer used.',
Expand Down
2 changes: 0 additions & 2 deletions phpstan.dist.neon
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@ parameters:
- CodeIgniter\Shield\Config\Services
ignoreErrors:
- identifier: function.internal
- identifier: return.internalClass
- identifier: staticMethod.internal
-
message: '#Dynamic call to static method PHPUnit\\#'
identifier: staticMethod.dynamicCall
4 changes: 2 additions & 2 deletions pyrameter.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@

use Boundwize\Pyrameter\Config\PyrameterConfig;
use Boundwize\Pyrameter\TestKind;
use CodeIgniter\Shield\Tests\Authentication\Filters\AbstractFilterTestCase;
use CodeIgniter\Shield\Tests\DatabaseTestCase;
use CodeIgniter\Test\DatabaseTestTrait;
use CodeIgniter\Test\FeatureTestTrait;
use Tests\Authentication\Filters\AbstractFilterTestCase;
use Tests\Support\DatabaseTestCase;

return PyrameterConfig::create()
->usesClass(
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/AccessTokenTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication;
namespace CodeIgniter\Shield\Tests\Authentication;

use CodeIgniter\Shield\Entities\AccessToken;
use Tests\Support\DatabaseTestCase;
use CodeIgniter\Shield\Tests\DatabaseTestCase;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/AuthHelperTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication;
namespace CodeIgniter\Shield\Tests\Authentication;

use CodeIgniter\Shield\Authentication\AuthenticationException;
use CodeIgniter\Shield\Models\UserModel;
use CodeIgniter\Shield\Tests\TestCase;
use CodeIgniter\Test\DatabaseTestTrait;
use Tests\Support\TestCase;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/AuthTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication;
namespace CodeIgniter\Shield\Tests\Authentication;

use CodeIgniter\Shield\Config\Services;
use Tests\Support\DatabaseTestCase;
use CodeIgniter\Shield\Tests\DatabaseTestCase;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/AuthenticationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication;
namespace CodeIgniter\Shield\Tests\Authentication;

use CodeIgniter\Shield\Authentication\Authentication;
use CodeIgniter\Shield\Authentication\AuthenticationException;
use CodeIgniter\Shield\Authentication\Authenticators\Session;
use CodeIgniter\Shield\Config\Auth;
use CodeIgniter\Shield\Models\UserModel;
use Tests\Support\DatabaseTestCase;
use CodeIgniter\Shield\Tests\DatabaseTestCase;

/**
* @internal
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Authenticators;
namespace CodeIgniter\Shield\Tests\Authentication\Authenticators;

use CodeIgniter\I18n\Time;
use CodeIgniter\Shield\Authentication\Authentication;
Expand All @@ -22,9 +22,9 @@
use CodeIgniter\Shield\Entities\User;
use CodeIgniter\Shield\Models\UserIdentityModel;
use CodeIgniter\Shield\Models\UserModel;
use CodeIgniter\Shield\Tests\DatabaseTestCase;
use CodeIgniter\Test\Mock\MockEvents;
use Config\Services;
use Tests\Support\DatabaseTestCase;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/Authenticators/HmacAuthenticatorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Authenticators;
namespace CodeIgniter\Shield\Tests\Authentication\Authenticators;

use CodeIgniter\I18n\Time;
use CodeIgniter\Shield\Authentication\Authentication;
Expand All @@ -22,9 +22,9 @@
use CodeIgniter\Shield\Entities\User;
use CodeIgniter\Shield\Models\UserIdentityModel;
use CodeIgniter\Shield\Models\UserModel;
use CodeIgniter\Shield\Tests\DatabaseTestCase;
use CodeIgniter\Test\Mock\MockEvents;
use Config\Services;
use Tests\Support\DatabaseTestCase;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/Authenticators/JWTAuthenticatorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Authenticators;
namespace CodeIgniter\Shield\Tests\Authentication\Authenticators;

use CodeIgniter\I18n\Time;
use CodeIgniter\Shield\Authentication\Authentication;
Expand All @@ -22,11 +22,11 @@
use CodeIgniter\Shield\Config\AuthJWT;
use CodeIgniter\Shield\Entities\User;
use CodeIgniter\Shield\Models\UserModel;
use CodeIgniter\Shield\Tests\DatabaseTestCase;
use CodeIgniter\Test\Mock\MockEvents;
use Config\Services;
use Firebase\JWT\JWT as FirebaseJWT;
use InvalidArgumentException;
use Tests\Support\DatabaseTestCase;

/**
* @internal
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Authenticators;
namespace CodeIgniter\Shield\Tests\Authentication\Authenticators;

use CodeIgniter\Config\Factories;
use CodeIgniter\Shield\Authentication\Authentication;
Expand All @@ -23,11 +23,11 @@
use CodeIgniter\Shield\Exceptions\LogicException;
use CodeIgniter\Shield\Models\RememberModel;
use CodeIgniter\Shield\Models\UserModel;
use CodeIgniter\Shield\Tests\DatabaseTestCase;
use CodeIgniter\Shield\Tests\FakeUser;
use CodeIgniter\Test\Mock\MockEvents;
use Config\Services;
use PHPUnit\Framework\Attributes\DataProvider;
use Tests\Support\DatabaseTestCase;
use Tests\Support\FakeUser;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/Filters/AbstractFilterTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Filters;
namespace CodeIgniter\Shield\Tests\Authentication\Filters;

use CodeIgniter\Config\Factories;
use CodeIgniter\Shield\Test\AuthenticationTesting;
use CodeIgniter\Shield\Tests\TestCase;
use CodeIgniter\Test\FeatureTestTrait;
use Config\Services;
use Tests\Support\TestCase;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/Filters/AuthRatesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Filters;
namespace CodeIgniter\Shield\Tests\Authentication\Filters;

use CodeIgniter\HTTP\CLIRequest;
use CodeIgniter\HTTP\IncomingRequest;
use CodeIgniter\HTTP\ResponseInterface;
use CodeIgniter\Shield\Filters\AuthRates;
use CodeIgniter\Shield\Tests\TestCase;
use CodeIgniter\Throttle\Throttler;
use Config\Services;
use Tests\Support\TestCase;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/Filters/ChainFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Filters;
namespace CodeIgniter\Shield\Tests\Authentication\Filters;

use CodeIgniter\Shield\Entities\AccessToken;
use CodeIgniter\Shield\Filters\ChainAuth;
use CodeIgniter\Shield\Tests\FakeUser;
use CodeIgniter\Test\DatabaseTestTrait;
use Tests\Support\FakeUser;

/**
* @internal
Expand Down
2 changes: 1 addition & 1 deletion tests/Authentication/Filters/GroupFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Filters;
namespace CodeIgniter\Shield\Tests\Authentication\Filters;

use CodeIgniter\Shield\Filters\GroupFilter;
use CodeIgniter\Shield\Models\UserModel;
Expand Down
2 changes: 1 addition & 1 deletion tests/Authentication/Filters/HmacFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Filters;
namespace CodeIgniter\Shield\Tests\Authentication\Filters;

use CodeIgniter\Shield\Entities\AccessToken;
use CodeIgniter\Shield\Entities\User;
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/Filters/JWTFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Filters;
namespace CodeIgniter\Shield\Tests\Authentication\Filters;

use CodeIgniter\Config\Factories;
use CodeIgniter\Shield\Authentication\Authenticators\JWT;
Expand All @@ -20,9 +20,9 @@
use CodeIgniter\Shield\Entities\User;
use CodeIgniter\Shield\Filters\JWTAuth;
use CodeIgniter\Shield\Models\UserModel;
use CodeIgniter\Shield\Tests\DatabaseTestCase;
use CodeIgniter\Test\FeatureTestTrait;
use Config\Services;
use Tests\Support\DatabaseTestCase;

/**
* @internal
Expand Down
2 changes: 1 addition & 1 deletion tests/Authentication/Filters/PermissionFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Filters;
namespace CodeIgniter\Shield\Tests\Authentication\Filters;

use CodeIgniter\Shield\Filters\PermissionFilter;
use CodeIgniter\Shield\Models\UserModel;
Expand Down
2 changes: 1 addition & 1 deletion tests/Authentication/Filters/SessionFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Filters;
namespace CodeIgniter\Shield\Tests\Authentication\Filters;

use CodeIgniter\I18n\Time;
use CodeIgniter\Shield\Authentication\Authenticators\Session;
Expand Down
2 changes: 1 addition & 1 deletion tests/Authentication/Filters/TokenFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication\Filters;
namespace CodeIgniter\Shield\Tests\Authentication\Filters;

use CodeIgniter\Shield\Entities\AccessToken;
use CodeIgniter\Shield\Entities\User;
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/ForcePasswordResetTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication;
namespace CodeIgniter\Shield\Tests\Authentication;

use CodeIgniter\Shield\Models\UserIdentityModel;
use CodeIgniter\Shield\Models\UserModel;
use CodeIgniter\Shield\Test\AuthenticationTesting;
use CodeIgniter\Shield\Tests\TestCase;
use CodeIgniter\Test\DatabaseTestTrait;
use CodeIgniter\Test\FeatureTestTrait;
use Config\Services;
use Tests\Support\TestCase;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/HasAccessTokensTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication;
namespace CodeIgniter\Shield\Tests\Authentication;

use CodeIgniter\I18n\Time;
use CodeIgniter\Shield\Entities\AccessToken;
use CodeIgniter\Shield\Entities\User;
use CodeIgniter\Shield\Models\UserIdentityModel;
use CodeIgniter\Shield\Models\UserModel;
use Tests\Support\DatabaseTestCase;
use CodeIgniter\Shield\Tests\DatabaseTestCase;

/**
* @internal
Expand Down
4 changes: 2 additions & 2 deletions tests/Authentication/HasHmacTokensTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
* the LICENSE file that was distributed with this source code.
*/

namespace Tests\Authentication;
namespace CodeIgniter\Shield\Tests\Authentication;

use CodeIgniter\I18n\Time;
use CodeIgniter\Shield\Entities\AccessToken;
use CodeIgniter\Shield\Entities\User;
use CodeIgniter\Shield\Models\UserIdentityModel;
use CodeIgniter\Shield\Models\UserModel;
use Tests\Support\DatabaseTestCase;
use CodeIgniter\Shield\Tests\DatabaseTestCase;

/**
* @internal
Expand Down
Loading
Loading