mirror of
https://github.com/archtechx/tenancy.git
synced 2026-02-05 08:24:05 +00:00
wip
This commit is contained in:
parent
d527191b89
commit
265216f7dc
4 changed files with 22 additions and 7 deletions
|
|
@ -48,7 +48,7 @@ abstract class TestCase extends \Orchestra\Testbench\TestCase
|
|||
protected function getEnvironmentSetUp($app)
|
||||
{
|
||||
if (file_exists(__DIR__ . '/../.env')) {
|
||||
\Dotenv\Dotenv::create(__DIR__ . '/..')->load();
|
||||
$this->loadDotEnv();
|
||||
}
|
||||
|
||||
$app['config']->set([
|
||||
|
|
@ -75,6 +75,15 @@ abstract class TestCase extends \Orchestra\Testbench\TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
protected function loadDotEnv()
|
||||
{
|
||||
if (app()::VERSION > '5.8.0') {
|
||||
\Dotenv\Dotenv::create(__DIR__ . '/..')->load();
|
||||
} else {
|
||||
(new \Dotenv\Dotenv(__DIR__ . '/..'))->load();
|
||||
}
|
||||
}
|
||||
|
||||
protected function getPackageProviders($app)
|
||||
{
|
||||
return [\Stancl\Tenancy\TenancyServiceProvider::class];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue