mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 12:54:05 +00:00
Fix bug with JSON encoding
This commit is contained in:
parent
8456280ac4
commit
314b2d3003
2 changed files with 37 additions and 5 deletions
|
|
@ -148,4 +148,20 @@ class TenantStorageTest extends TestCase
|
|||
config(['tenancy.storage.db.connection' => 'foo']);
|
||||
$this->assertSame('foo', (new Tenant)->getConnectionName());
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function retrieving_data_without_cache_works()
|
||||
{
|
||||
tenant()->create('foo.localhost');
|
||||
tenancy()->init('foo.localhost');
|
||||
|
||||
tenancy()->put('foo', 'bar');
|
||||
$this->assertSame('bar', tenancy()->get('foo'));
|
||||
$this->assertSame(['bar'], tenancy()->get(['foo']));
|
||||
|
||||
tenancy()->end();
|
||||
tenancy()->init('foo.localhost');
|
||||
$this->assertSame('bar', tenancy()->get('foo'));
|
||||
$this->assertSame(['bar'], tenancy()->get(['foo']));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue