diff --git a/src/Illuminate/Foundation/Testing/Concerns/InteractsWithCacheTable.php b/src/Illuminate/Foundation/Testing/Concerns/InteractsWithCacheTable.php deleted file mode 100644 index bf9cbfad6c1b..000000000000 --- a/src/Illuminate/Foundation/Testing/Concerns/InteractsWithCacheTable.php +++ /dev/null @@ -1,36 +0,0 @@ -string('key')->primary(); - $table->mediumText('value'); - $table->integer('expiration'); - }); - - Schema::create('cache_locks', function (Blueprint $table) { - $table->string('key')->primary(); - $table->string('owner'); - $table->integer('expiration'); - }); - } - - /** - * Drop all cache related table tables. - */ - protected function dropCacheTables() - { - Schema::dropIfExists('cache'); - Schema::dropIfExists('cache_locks'); - } -} diff --git a/tests/Integration/Database/DatabaseCacheStoreTest.php b/tests/Integration/Database/DatabaseCacheStoreTest.php index 6af08a7e3b0b..1f5bac9835d0 100644 --- a/tests/Integration/Database/DatabaseCacheStoreTest.php +++ b/tests/Integration/Database/DatabaseCacheStoreTest.php @@ -2,24 +2,13 @@ namespace Illuminate\Tests\Integration\Database; -use Illuminate\Foundation\Testing\Concerns\InteractsWithCacheTable; use Illuminate\Support\Facades\Cache; use Illuminate\Support\Facades\DB; +use Orchestra\Testbench\Attributes\WithMigration; +#[WithMigration('cache')] class DatabaseCacheStoreTest extends DatabaseTestCase { - use InteractsWithCacheTable; - - protected function defineDatabaseMigrationsAfterDatabaseRefreshed() - { - $this->createCacheTables(); - } - - protected function destroyDatabaseMigrations() - { - $this->dropCacheTables(); - } - public function testValueCanStoreNewCache() { $store = $this->getStore();