mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 20:54:04 +00:00
Refactor more old code and get tests to pass
This commit is contained in:
parent
c5377a16f7
commit
c32f229dd5
72 changed files with 425 additions and 531 deletions
|
|
@ -1,10 +1,10 @@
|
|||
<?php
|
||||
|
||||
namespace Stancl\Tenancy\Tests\v3;
|
||||
namespace Stancl\Tenancy\Tests;
|
||||
|
||||
use Illuminate\Support\Facades\Route;
|
||||
use Stancl\Tenancy\Database\Models;
|
||||
use Stancl\Tenancy\Database\Models\Concerns\HasDomains;
|
||||
use Stancl\Tenancy\Database\Concerns\HasDomains;
|
||||
use Stancl\Tenancy\Middleware\InitializeTenancyByDomainOrSubdomain;
|
||||
use Stancl\Tenancy\Tests\TestCase;
|
||||
|
||||
|
|
@ -22,7 +22,7 @@ class CombinedDomainAndSubdomainIdentificationTest extends TestCase
|
|||
});
|
||||
});
|
||||
|
||||
config(['tenancy.tenant_model' => Tenant::class]);
|
||||
config(['tenancy.tenant_model' => CombinedTenant::class]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
|
|
@ -30,7 +30,7 @@ class CombinedDomainAndSubdomainIdentificationTest extends TestCase
|
|||
{
|
||||
config(['tenancy.central_domains' => ['localhost']]);
|
||||
|
||||
$tenant = Tenant::create([
|
||||
$tenant = CombinedTenant::create([
|
||||
'id' => 'acme',
|
||||
]);
|
||||
|
||||
|
|
@ -53,7 +53,7 @@ class CombinedDomainAndSubdomainIdentificationTest extends TestCase
|
|||
{
|
||||
config(['tenancy.central_domains' => []]);
|
||||
|
||||
$tenant = Tenant::create([
|
||||
$tenant = CombinedTenant::create([
|
||||
'id' => 'acme',
|
||||
]);
|
||||
|
||||
|
|
@ -72,7 +72,7 @@ class CombinedDomainAndSubdomainIdentificationTest extends TestCase
|
|||
}
|
||||
}
|
||||
|
||||
class Tenant extends Models\Tenant
|
||||
class CombinedTenant extends Models\Tenant
|
||||
{
|
||||
use HasDomains;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue