mirror of
https://github.com/archtechx/tenancy.git
synced 2026-02-05 18:54:03 +00:00
skip tests for old versions
This commit is contained in:
parent
b0876ae8d8
commit
abd55556e2
1 changed files with 5 additions and 0 deletions
|
|
@ -6,6 +6,7 @@ namespace Stancl\Tenancy\Tests;
|
||||||
|
|
||||||
use Illuminate\Bus\BatchRepository;
|
use Illuminate\Bus\BatchRepository;
|
||||||
use Illuminate\Support\Facades\Event;
|
use Illuminate\Support\Facades\Event;
|
||||||
|
use Illuminate\Support\Str;
|
||||||
use ReflectionClass;
|
use ReflectionClass;
|
||||||
use Stancl\Tenancy\Bootstrappers\BatchTenancyBootstrapper;
|
use Stancl\Tenancy\Bootstrappers\BatchTenancyBootstrapper;
|
||||||
use Stancl\Tenancy\Bootstrappers\DatabaseTenancyBootstrapper;
|
use Stancl\Tenancy\Bootstrappers\DatabaseTenancyBootstrapper;
|
||||||
|
|
@ -37,6 +38,10 @@ class BatchTest extends TestCase
|
||||||
/** @test */
|
/** @test */
|
||||||
public function batch_repository_is_set_to_tenant_connection_and_reverted()
|
public function batch_repository_is_set_to_tenant_connection_and_reverted()
|
||||||
{
|
{
|
||||||
|
if (! version_compare(app()->version(), '8.0', '>=')) {
|
||||||
|
$this->markTestSkipped('Job batches are only supported in Laravel 8+');
|
||||||
|
}
|
||||||
|
|
||||||
$tenant = Tenant::create();
|
$tenant = Tenant::create();
|
||||||
|
|
||||||
$this->assertEquals('central', $this->getBatchRepositoryConnectionName(), 'Expected initial connection to be central');
|
$this->assertEquals('central', $this->getBatchRepositoryConnectionName(), 'Expected initial connection to be central');
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue