mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 12:54:05 +00:00
Get Redis tests to pass
This commit is contained in:
parent
6b0ec1b554
commit
fb58f21f1c
3 changed files with 51 additions and 30 deletions
|
|
@ -15,14 +15,14 @@ class TenantAssetTest extends TestCase
|
|||
|
||||
// response()->file() returns BinaryFileResponse whose content is
|
||||
// inaccessible via getContent, so ->assertSee() can't be used
|
||||
// $this->get(tenant_asset($filename))->assertSuccessful(); // TODO2 COMMENTED ASSERTIONS
|
||||
// $this->assertFileExists($path); // TODO2 COMMENTED ASSERTIONS
|
||||
// $this->get(tenant_asset($filename))->assertSuccessful(); // todo commented assertions
|
||||
// $this->assertFileExists($path); // todo commented assertions
|
||||
|
||||
$f = \fopen($path, 'r');
|
||||
$content = \fread($f, \filesize($path));
|
||||
\fclose($f);
|
||||
$f = fopen($path, 'r');
|
||||
$content = fread($f, filesize($path));
|
||||
fclose($f);
|
||||
|
||||
// $this->assertSame('bar', $content); // TODO2 COMMENTED ASSERTIONS
|
||||
$this->assertTrue(true); // TODO2 COMMENTED ASSERTIONS
|
||||
// $this->assertSame('bar', $content); // todo commented assertions
|
||||
$this->assertTrue(true);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -187,4 +187,11 @@ class TenantManagerTest extends TestCase
|
|||
$this->expectException(\Stancl\Tenancy\Exceptions\TenantStorageException::class);
|
||||
$tenant2->put('id', 'foo');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function all_returns_a_collection_of_tenant_objects()
|
||||
{
|
||||
Tenant::create('foo.localhost');
|
||||
$this->assertSame('Tenant', class_basename(tenancy()->all()[0]));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue