1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2026-02-05 20:34:03 +00:00

Adopt expectation API

This commit is contained in:
Shift 2022-06-28 20:56:06 +00:00
parent 5637018b0d
commit cef9529d6a
No known key found for this signature in database
GPG key ID: 5A96F038425C5A1C
22 changed files with 278 additions and 278 deletions

View file

@ -29,7 +29,7 @@ test('database can be created after tenant creation', function () {
$manager = app(MySQLDatabaseManager::class);
$manager->setConnection('mysql');
$this->assertTrue($manager->databaseExists($tenant->database()->getName()));
expect($manager->databaseExists($tenant->database()->getName()))->toBeTrue();
});
test('database can be migrated after tenant creation', function () {
@ -43,7 +43,7 @@ test('database can be migrated after tenant creation', function () {
$tenant = Tenant::create();
$tenant->run(function () {
$this->assertTrue(Schema::hasTable('users'));
expect(Schema::hasTable('users'))->toBeTrue();
});
});
@ -63,7 +63,7 @@ test('database can be seeded after tenant creation', function () {
$tenant = Tenant::create();
$tenant->run(function () {
$this->assertSame('Seeded User', User::first()->name);
expect(User::first()->name)->toBe('Seeded User');
});
});
@ -84,7 +84,7 @@ test('custom job can be added to the pipeline', function () {
$tenant = Tenant::create();
$tenant->run(function () {
$this->assertSame('Foo', User::all()[1]->name);
expect(User::all()[1]->name)->toBe('Foo');
});
});