diff --git a/src/Bootstrappers/CacheTaggingBootstrapper.php b/src/Bootstrappers/CacheTagsBootstrapper.php similarity index 85% rename from src/Bootstrappers/CacheTaggingBootstrapper.php rename to src/Bootstrappers/CacheTagsBootstrapper.php index 57a3502b..1e9bb90d 100644 --- a/src/Bootstrappers/CacheTaggingBootstrapper.php +++ b/src/Bootstrappers/CacheTagsBootstrapper.php @@ -9,9 +9,11 @@ use Stancl\Tenancy\Contracts\TenancyBootstrapper; use Stancl\Tenancy\Contracts\Tenant; /** + * todo name + * * Separate tenant cache using tagging. */ -class CacheTaggingBootstrapper implements TenancyBootstrapper +class CacheTagsBootstrapper implements TenancyBootstrapper { public function bootstrap(Tenant $tenant): void { diff --git a/tests/BootstrapperTest.php b/tests/BootstrapperTest.php index af603479..a71b54d4 100644 --- a/tests/BootstrapperTest.php +++ b/tests/BootstrapperTest.php @@ -28,7 +28,7 @@ use Stancl\Tenancy\Listeners\BootstrapTenancy; use Stancl\Tenancy\Tests\Etc\TestingBroadcaster; use Stancl\Tenancy\Listeners\DeleteTenantStorage; use Stancl\Tenancy\Listeners\RevertToCentralContext; -use Stancl\Tenancy\Bootstrappers\CacheTaggingBootstrapper; +use Stancl\Tenancy\Bootstrappers\CacheTagsBootstrapper; use Stancl\Tenancy\Bootstrappers\UrlTenancyBootstrapper; use Stancl\Tenancy\Bootstrappers\MailTenancyBootstrapper; use Stancl\Tenancy\Bootstrappers\RedisTenancyBootstrapper; @@ -85,7 +85,7 @@ test('database data is separated', function () { test('cache data is separated', function () { config([ 'tenancy.bootstrappers' => [ - CacheTaggingBootstrapper::class, + CacheTagsBootstrapper::class, ], 'cache.default' => 'redis', ]); diff --git a/tests/CacheManagerTest.php b/tests/CacheManagerTest.php index b3930756..f0e8c2a1 100644 --- a/tests/CacheManagerTest.php +++ b/tests/CacheManagerTest.php @@ -6,10 +6,10 @@ use Stancl\Tenancy\Tests\Etc\Tenant; use Illuminate\Support\Facades\Event; use Stancl\Tenancy\Events\TenancyInitialized; use Stancl\Tenancy\Listeners\BootstrapTenancy; -use Stancl\Tenancy\Bootstrappers\CacheTaggingBootstrapper; +use Stancl\Tenancy\Bootstrappers\CacheTagsBootstrapper; beforeEach(function () { - config(['tenancy.bootstrappers' => [CacheTaggingBootstrapper::class]]); + config(['tenancy.bootstrappers' => [CacheTagsBootstrapper::class]]); Event::listen(TenancyInitialized::class, BootstrapTenancy::class); }); diff --git a/tests/GlobalCacheTest.php b/tests/GlobalCacheTest.php index 465d7bd7..6106a13c 100644 --- a/tests/GlobalCacheTest.php +++ b/tests/GlobalCacheTest.php @@ -9,10 +9,10 @@ use Stancl\Tenancy\Facades\GlobalCache; use Stancl\Tenancy\Events\TenancyInitialized; use Stancl\Tenancy\Listeners\BootstrapTenancy; use Stancl\Tenancy\Listeners\RevertToCentralContext; -use Stancl\Tenancy\Bootstrappers\CacheTaggingBootstrapper; +use Stancl\Tenancy\Bootstrappers\CacheTagsBootstrapper; beforeEach(function () { - config(['tenancy.bootstrappers' => [CacheTaggingBootstrapper::class]]); + config(['tenancy.bootstrappers' => [CacheTagsBootstrapper::class]]); Event::listen(TenancyInitialized::class, BootstrapTenancy::class); Event::listen(TenancyEnded::class, RevertToCentralContext::class);