mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 11:34:03 +00:00
Add TestCase@initTenancy
This commit is contained in:
parent
124e747aa0
commit
3857c4a27d
2 changed files with 9 additions and 4 deletions
|
|
@ -16,7 +16,7 @@ class TestCase extends \Orchestra\Testbench\TestCase
|
|||
protected function setUp()
|
||||
{
|
||||
parent::setUp();
|
||||
|
||||
|
||||
Redis::connection('tenancy')->flushdb();
|
||||
|
||||
tenant()->create('localhost');
|
||||
|
|
@ -84,4 +84,9 @@ class TestCase extends \Orchestra\Testbench\TestCase
|
|||
// set one of these environment vars on their computer.
|
||||
return env('CI') && env('TRAVIS') && env('CONTINUOUS_INTEGRATION');
|
||||
}
|
||||
|
||||
public function initTenancy($domain = 'localhost')
|
||||
{
|
||||
tenancy()->init($domain);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue