mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 15:34:03 +00:00
global_asset test
This commit is contained in:
parent
b9054864aa
commit
bd08979e0c
1 changed files with 11 additions and 1 deletions
|
|
@ -55,5 +55,15 @@ class TenantAssetTest extends TestCase
|
||||||
$this->assertSame("https://an-s3-bucket/tenant{$tenant->id}/foo", asset('foo'));
|
$this->assertSame("https://an-s3-bucket/tenant{$tenant->id}/foo", asset('foo'));
|
||||||
}
|
}
|
||||||
|
|
||||||
// todo test global asset
|
/** @test */
|
||||||
|
public function global_asset_helper_returns_the_same_url_regardless_of_tenancy_initialization()
|
||||||
|
{
|
||||||
|
$original = global_asset('foobar');
|
||||||
|
$this->assertSame(asset('foobar'), global_asset('foobar'));
|
||||||
|
|
||||||
|
Tenant::create(['foo.localhost']);
|
||||||
|
tenancy()->init('foo.localhost');
|
||||||
|
|
||||||
|
$this->assertSame($original, global_asset('foobar'));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue