mirror of
https://github.com/archtechx/tenancy.git
synced 2026-02-06 01:44:04 +00:00
Adopt expectation API
This commit is contained in:
parent
5637018b0d
commit
cef9529d6a
22 changed files with 278 additions and 278 deletions
|
|
@ -34,6 +34,6 @@ test('tenant route helper generates correct url', function () {
|
|||
return 'Foo';
|
||||
})->name('foo');
|
||||
|
||||
$this->assertSame('http://foo.localhost/abcdef/as/df', tenant_route('foo.localhost', 'foo', ['a' => 'as', 'b' => 'df']));
|
||||
$this->assertSame('http://foo.localhost/abcdef', tenant_route('foo.localhost', 'foo', []));
|
||||
expect(tenant_route('foo.localhost', 'foo', ['a' => 'as', 'b' => 'df']))->toBe('http://foo.localhost/abcdef/as/df');
|
||||
expect(tenant_route('foo.localhost', 'foo', []))->toBe('http://foo.localhost/abcdef');
|
||||
});
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ afterEach(function () {
|
|||
});
|
||||
|
||||
test('config is merged and removed', function () {
|
||||
$this->assertSame(null, config('services.paypal'));
|
||||
expect(config('services.paypal'))->toBe(null);
|
||||
config([
|
||||
'tenancy.features' => [TenantConfig::class],
|
||||
'tenancy.bootstrappers' => [],
|
||||
|
|
@ -37,7 +37,7 @@ test('config is merged and removed', function () {
|
|||
]);
|
||||
|
||||
tenancy()->initialize($tenant);
|
||||
$this->assertSame(['public' => 'foo', 'private' => 'bar'], config('services.paypal'));
|
||||
expect(config('services.paypal'))->toBe(['public' => 'foo', 'private' => 'bar']);
|
||||
|
||||
tenancy()->end();
|
||||
$this->assertSame([
|
||||
|
|
@ -47,7 +47,7 @@ test('config is merged and removed', function () {
|
|||
});
|
||||
|
||||
test('the value can be set to multiple config keys', function () {
|
||||
$this->assertSame(null, config('services.paypal'));
|
||||
expect(config('services.paypal'))->toBe(null);
|
||||
config([
|
||||
'tenancy.features' => [TenantConfig::class],
|
||||
'tenancy.bootstrappers' => [],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue