1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2026-02-06 03:14:04 +00:00

drop laravel < 9 support

This commit is contained in:
Samuel Štancl 2023-02-16 11:55:23 +01:00
parent eca3b79118
commit 89c5029fd6
7 changed files with 20 additions and 32 deletions

View file

@ -207,10 +207,6 @@ class BootstrapperTest extends TestCase
$disk = Storage::disk($disk);
$adapter = $disk->getAdapter();
if (! Str::startsWith(app()->version(), '9.')) {
return $adapter->getPathPrefix();
}
$prefixer = (new ReflectionObject($adapter))->getProperty('prefixer');
$prefixer->setAccessible(true);

View file

@ -12,10 +12,6 @@ class ViteBundlerTest extends TestCase
/** @test */
public function the_vite_helper_uses_our_custom_class()
{
if (version_compare(app()->version(), '9.0', '<')) {
$this->markTestSkipped('Vite is only used in Laravel 9+');
}
$vite = app(\Illuminate\Foundation\Vite::class);
$this->assertInstanceOf(\Illuminate\Foundation\Vite::class, $vite);

View file

@ -194,9 +194,7 @@ class TenantDatabaseManagerTest extends TestCase
]);
tenancy()->initialize($tenant);
$schemaConfig = version_compare(app()->version(), '9.0', '>=') ?
config('database.connections.' . config('database.default') . '.search_path') :
config('database.connections.' . config('database.default') . '.schema');
$schemaConfig = config('database.connections.' . config('database.default') . '.search_path');
$this->assertSame($tenant->database()->getName(), $schemaConfig);
$this->assertSame($originalDatabaseName, config(['database.connections.pgsql.database']));