diff --git a/src/Authenticator.php b/src/Authenticator.php index e80375f..ebe6064 100644 --- a/src/Authenticator.php +++ b/src/Authenticator.php @@ -6,8 +6,8 @@ use Intervention\HttpAuth\Exceptions\NotSupportedException; use Intervention\HttpAuth\Interfaces\VaultInterface; -use Intervention\HttpAuth\Vault\BasicVault; -use Intervention\HttpAuth\Vault\DigestVault; +use Intervention\HttpAuth\Vaults\BasicVault; +use Intervention\HttpAuth\Vaults\DigestVault; class Authenticator { diff --git a/src/Environment.php b/src/Environment.php index 181681b..c689ef7 100644 --- a/src/Environment.php +++ b/src/Environment.php @@ -16,11 +16,11 @@ class Environment implements EnvironmentInterface * @var array */ protected static $tokenClassnames = [ - Token\PhpAuthUser::class, - Token\HttpAuthentification::class, - Token\RedirectHttpAuthorization::class, - Token\PhpAuthDigest::class, - Token\HttpAuthorization::class, + Tokens\PhpAuthUser::class, + Tokens\HttpAuthentification::class, + Tokens\RedirectHttpAuthorization::class, + Tokens\PhpAuthDigest::class, + Tokens\HttpAuthorization::class, ]; /** diff --git a/src/Token/AbstractToken.php b/src/Tokens/AbstractToken.php similarity index 98% rename from src/Token/AbstractToken.php rename to src/Tokens/AbstractToken.php index 598fc68..92d2908 100644 --- a/src/Token/AbstractToken.php +++ b/src/Tokens/AbstractToken.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Token; +namespace Intervention\HttpAuth\Tokens; use Intervention\HttpAuth\Interfaces\TokenInterface; diff --git a/src/Token/HttpAuthentification.php b/src/Tokens/HttpAuthentification.php similarity index 95% rename from src/Token/HttpAuthentification.php rename to src/Tokens/HttpAuthentification.php index 2def96c..54736d6 100644 --- a/src/Token/HttpAuthentification.php +++ b/src/Tokens/HttpAuthentification.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Token; +namespace Intervention\HttpAuth\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; diff --git a/src/Token/HttpAuthorization.php b/src/Tokens/HttpAuthorization.php similarity index 96% rename from src/Token/HttpAuthorization.php rename to src/Tokens/HttpAuthorization.php index a782c7d..db5595f 100644 --- a/src/Token/HttpAuthorization.php +++ b/src/Tokens/HttpAuthorization.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Token; +namespace Intervention\HttpAuth\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; diff --git a/src/Token/PhpAuthDigest.php b/src/Tokens/PhpAuthDigest.php similarity index 95% rename from src/Token/PhpAuthDigest.php rename to src/Tokens/PhpAuthDigest.php index e22b1c0..5e55c1c 100644 --- a/src/Token/PhpAuthDigest.php +++ b/src/Tokens/PhpAuthDigest.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Token; +namespace Intervention\HttpAuth\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; diff --git a/src/Token/PhpAuthUser.php b/src/Tokens/PhpAuthUser.php similarity index 94% rename from src/Token/PhpAuthUser.php rename to src/Tokens/PhpAuthUser.php index 61e392b..d9c53e0 100644 --- a/src/Token/PhpAuthUser.php +++ b/src/Tokens/PhpAuthUser.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Token; +namespace Intervention\HttpAuth\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; diff --git a/src/Token/RedirectHttpAuthorization.php b/src/Tokens/RedirectHttpAuthorization.php similarity index 95% rename from src/Token/RedirectHttpAuthorization.php rename to src/Tokens/RedirectHttpAuthorization.php index 451abec..df06cb9 100644 --- a/src/Token/RedirectHttpAuthorization.php +++ b/src/Tokens/RedirectHttpAuthorization.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Token; +namespace Intervention\HttpAuth\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; diff --git a/src/Vault/AbstractVault.php b/src/Vaults/AbstractVault.php similarity index 98% rename from src/Vault/AbstractVault.php rename to src/Vaults/AbstractVault.php index aa951e4..25a28f1 100644 --- a/src/Vault/AbstractVault.php +++ b/src/Vaults/AbstractVault.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Vault; +namespace Intervention\HttpAuth\Vaults; use Intervention\HttpAuth\Environment; use Intervention\HttpAuth\Exceptions\AuthentificationException; diff --git a/src/Vault/BasicVault.php b/src/Vaults/BasicVault.php similarity index 96% rename from src/Vault/BasicVault.php rename to src/Vaults/BasicVault.php index 895a35a..52313b2 100644 --- a/src/Vault/BasicVault.php +++ b/src/Vaults/BasicVault.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Vault; +namespace Intervention\HttpAuth\Vaults; use Intervention\HttpAuth\Directive; use Intervention\HttpAuth\Exceptions\AuthentificationException; diff --git a/src/Vault/DigestVault.php b/src/Vaults/DigestVault.php similarity index 97% rename from src/Vault/DigestVault.php rename to src/Vaults/DigestVault.php index a8de885..e20784f 100644 --- a/src/Vault/DigestVault.php +++ b/src/Vaults/DigestVault.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Vault; +namespace Intervention\HttpAuth\Vaults; use Intervention\HttpAuth\Directive; use Intervention\HttpAuth\Exceptions\AuthentificationException; diff --git a/tests/Unit/AbstractVaultTest.php b/tests/Unit/AbstractVaultTest.php index bb4ca0d..6afc1e3 100644 --- a/tests/Unit/AbstractVaultTest.php +++ b/tests/Unit/AbstractVaultTest.php @@ -7,7 +7,7 @@ use Intervention\HttpAuth\Directive; use Intervention\HttpAuth\Interfaces\TokenInterface; use Intervention\HttpAuth\Type; -use Intervention\HttpAuth\Vault\AbstractVault; +use Intervention\HttpAuth\Vaults\AbstractVault; use PHPUnit\Framework\TestCase; final class AbstractVaultTest extends TestCase diff --git a/tests/Unit/AuthenticatorTest.php b/tests/Unit/AuthenticatorTest.php index 629c037..64934af 100644 --- a/tests/Unit/AuthenticatorTest.php +++ b/tests/Unit/AuthenticatorTest.php @@ -5,7 +5,7 @@ namespace Intervention\HttpAuth\Tests\Unit; use Intervention\HttpAuth\Authenticator; -use Intervention\HttpAuth\Vault\BasicVault; +use Intervention\HttpAuth\Vaults\BasicVault; use PHPUnit\Framework\TestCase; final class AuthenticatorTest extends TestCase diff --git a/tests/Unit/Token/HttpAuthentificationTest.php b/tests/Unit/Tokens/HttpAuthentificationTest.php similarity index 88% rename from tests/Unit/Token/HttpAuthentificationTest.php rename to tests/Unit/Tokens/HttpAuthentificationTest.php index 23235ed..65bc249 100644 --- a/tests/Unit/Token/HttpAuthentificationTest.php +++ b/tests/Unit/Tokens/HttpAuthentificationTest.php @@ -2,11 +2,11 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Tests\Unit\Token; +namespace Intervention\HttpAuth\Tests\Unit\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; use Intervention\HttpAuth\Tests\TestCase; -use Intervention\HttpAuth\Token\HttpAuthentification; +use Intervention\HttpAuth\Tokens\HttpAuthentification; final class HttpAuthentificationTest extends TestCase { diff --git a/tests/Unit/Token/HttpAuthorizationTest.php b/tests/Unit/Tokens/HttpAuthorizationTest.php similarity index 90% rename from tests/Unit/Token/HttpAuthorizationTest.php rename to tests/Unit/Tokens/HttpAuthorizationTest.php index 415f2fa..3a4ae68 100644 --- a/tests/Unit/Token/HttpAuthorizationTest.php +++ b/tests/Unit/Tokens/HttpAuthorizationTest.php @@ -2,11 +2,11 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Tests\Unit\Token; +namespace Intervention\HttpAuth\Tests\Unit\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; use Intervention\HttpAuth\Tests\TestCase; -use Intervention\HttpAuth\Token\HttpAuthorization; +use Intervention\HttpAuth\Tokens\HttpAuthorization; final class HttpAuthorizationTest extends TestCase { diff --git a/tests/Unit/Token/PhpAuthDigestTest.php b/tests/Unit/Tokens/PhpAuthDigestTest.php similarity index 90% rename from tests/Unit/Token/PhpAuthDigestTest.php rename to tests/Unit/Tokens/PhpAuthDigestTest.php index 61261bd..fa8be8d 100644 --- a/tests/Unit/Token/PhpAuthDigestTest.php +++ b/tests/Unit/Tokens/PhpAuthDigestTest.php @@ -2,11 +2,11 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Tests\Unit\Token; +namespace Intervention\HttpAuth\Tests\Unit\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; use Intervention\HttpAuth\Tests\TestCase; -use Intervention\HttpAuth\Token\PhpAuthDigest; +use Intervention\HttpAuth\Tokens\PhpAuthDigest; final class PhpAuthDigestTest extends TestCase { diff --git a/tests/Unit/Token/PhpAuthUserTest.php b/tests/Unit/Tokens/PhpAuthUserTest.php similarity index 87% rename from tests/Unit/Token/PhpAuthUserTest.php rename to tests/Unit/Tokens/PhpAuthUserTest.php index b6ef9f8..d6cec54 100644 --- a/tests/Unit/Token/PhpAuthUserTest.php +++ b/tests/Unit/Tokens/PhpAuthUserTest.php @@ -2,11 +2,11 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Tests\Unit\Token; +namespace Intervention\HttpAuth\Tests\Unit\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; use Intervention\HttpAuth\Tests\TestCase; -use Intervention\HttpAuth\Token\PhpAuthUser; +use Intervention\HttpAuth\Tokens\PhpAuthUser; final class PhpAuthUserTest extends TestCase { diff --git a/tests/Unit/Token/RedirectHttpAuthorizationTest.php b/tests/Unit/Tokens/RedirectHttpAuthorizationTest.php similarity index 88% rename from tests/Unit/Token/RedirectHttpAuthorizationTest.php rename to tests/Unit/Tokens/RedirectHttpAuthorizationTest.php index fe96f2a..cc10f06 100644 --- a/tests/Unit/Token/RedirectHttpAuthorizationTest.php +++ b/tests/Unit/Tokens/RedirectHttpAuthorizationTest.php @@ -2,11 +2,11 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Tests\Unit\Token; +namespace Intervention\HttpAuth\Tests\Unit\Tokens; use Intervention\HttpAuth\Exceptions\AuthentificationException; use Intervention\HttpAuth\Tests\TestCase; -use Intervention\HttpAuth\Token\RedirectHttpAuthorization; +use Intervention\HttpAuth\Tokens\RedirectHttpAuthorization; final class RedirectHttpAuthorizationTest extends TestCase { diff --git a/tests/Unit/Vault/BasicVaultTest.php b/tests/Unit/Vaults/BasicVaultTest.php similarity index 91% rename from tests/Unit/Vault/BasicVaultTest.php rename to tests/Unit/Vaults/BasicVaultTest.php index fab15f5..6cc5ac8 100644 --- a/tests/Unit/Vault/BasicVaultTest.php +++ b/tests/Unit/Vaults/BasicVaultTest.php @@ -2,16 +2,16 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Tests\Unit\Vault; +namespace Intervention\HttpAuth\Tests\Unit\Vaults; -use Intervention\HttpAuth\Vault\BasicVault; +use Intervention\HttpAuth\Vaults\BasicVault; use Intervention\HttpAuth\Directive; use Intervention\HttpAuth\Exceptions\AuthentificationException; -use Intervention\HttpAuth\Token\HttpAuthentification; -use Intervention\HttpAuth\Token\HttpAuthorization; -use Intervention\HttpAuth\Token\PhpAuthDigest; -use Intervention\HttpAuth\Token\PhpAuthUser; -use Intervention\HttpAuth\Token\RedirectHttpAuthorization; +use Intervention\HttpAuth\Tokens\HttpAuthentification; +use Intervention\HttpAuth\Tokens\HttpAuthorization; +use Intervention\HttpAuth\Tokens\PhpAuthDigest; +use Intervention\HttpAuth\Tokens\PhpAuthUser; +use Intervention\HttpAuth\Tokens\RedirectHttpAuthorization; use PHPUnit\Framework\TestCase; final class BasicVaultTest extends TestCase diff --git a/tests/Unit/Vault/DigestVaultTest.php b/tests/Unit/Vaults/DigestVaultTest.php similarity index 91% rename from tests/Unit/Vault/DigestVaultTest.php rename to tests/Unit/Vaults/DigestVaultTest.php index 6fb7bd6..a2a7ecd 100644 --- a/tests/Unit/Vault/DigestVaultTest.php +++ b/tests/Unit/Vaults/DigestVaultTest.php @@ -2,16 +2,16 @@ declare(strict_types=1); -namespace Intervention\HttpAuth\Tests\Unit\Vault; +namespace Intervention\HttpAuth\Tests\Unit\Vaults; use Intervention\HttpAuth\Directive; use Intervention\HttpAuth\Exceptions\AuthentificationException; -use Intervention\HttpAuth\Token\HttpAuthentification; -use Intervention\HttpAuth\Token\HttpAuthorization; -use Intervention\HttpAuth\Token\PhpAuthDigest; -use Intervention\HttpAuth\Token\PhpAuthUser; -use Intervention\HttpAuth\Token\RedirectHttpAuthorization; -use Intervention\HttpAuth\Vault\DigestVault; +use Intervention\HttpAuth\Tokens\HttpAuthentification; +use Intervention\HttpAuth\Tokens\HttpAuthorization; +use Intervention\HttpAuth\Tokens\PhpAuthDigest; +use Intervention\HttpAuth\Tokens\PhpAuthUser; +use Intervention\HttpAuth\Tokens\RedirectHttpAuthorization; +use Intervention\HttpAuth\Vaults\DigestVault; use PHPUnit\Framework\TestCase; final class DigestVaultTest extends TestCase