mirror of
https://github.com/bitinflow/expose.git
synced 2026-03-15 06:25:56 +00:00
wip
This commit is contained in:
@@ -2,6 +2,10 @@
|
||||
|
||||
namespace Tests\Feature;
|
||||
|
||||
use Clue\React\SQLite\DatabaseInterface;
|
||||
use GuzzleHttp\Psr7\Response;
|
||||
use Illuminate\Support\Str;
|
||||
use Psr\Http\Message\ResponseInterface;
|
||||
use React\EventLoop\Factory;
|
||||
use React\EventLoop\LoopInterface;
|
||||
use React\EventLoop\StreamSelectLoop;
|
||||
@@ -33,4 +37,13 @@ abstract class TestCase extends \Tests\TestCase
|
||||
{
|
||||
return await($promise, $loop ?? $this->loop, $timeout ?? static::AWAIT_TIMEOUT);
|
||||
}
|
||||
|
||||
protected function assertDatabaseHasResults($query)
|
||||
{
|
||||
$database = app(DatabaseInterface::class);
|
||||
|
||||
$result = $this->await($database->query($query));
|
||||
|
||||
$this->assertGreaterThanOrEqual(1, count($result->rows));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user