mirror of
https://github.com/archtechx/tenancy.git
synced 2026-02-06 01:34:02 +00:00
convert test to pest
This commit is contained in:
parent
a7e1a17cd0
commit
cbdcec2bcd
2 changed files with 35 additions and 61 deletions
|
|
@ -1,11 +1,12 @@
|
|||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Stancl\Tenancy\Bootstrappers;
|
||||
|
||||
use Illuminate\Bus\BatchRepository;
|
||||
use Illuminate\Bus\DatabaseBatchRepository;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use ReflectionClass;
|
||||
use Stancl\Tenancy\Contracts\TenancyBootstrapper;
|
||||
use Stancl\Tenancy\Contracts\Tenant;
|
||||
|
||||
|
|
@ -32,10 +33,10 @@ class BatchTenancyBootstrapper implements TenancyBootstrapper
|
|||
public function revert()
|
||||
{
|
||||
if ($this->previousConnection) {
|
||||
// Access the resolved batch repository instance and replace its connection with the previously replaced one
|
||||
// Access the resolved batch repository instance and replace its connection with the previously replaced one
|
||||
$batchRepository = app(BatchRepository::class);
|
||||
$batchRepository->setConnection($this->previousConnection);
|
||||
$this->previousConnection = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue