Level 7
sorry I'm still debugging this, cant delete, but it looks like its the factory hanging.
Disregard :)
Just started new tests in Lumen API, it hangs when I run it with
vendor/bin/phpunit tests/ApiIntegrationTest.php
Very simple test so far:
<?php
use Laravel\Lumen\Testing\DatabaseMigrations;
use Laravel\Lumen\Testing\DatabaseTransactions;
class ApiIntegrationTest extends TestCase
{
use DatabaseMigrations;
/** @test */
public function get_benefits_list()
{
$benefits = factory(\App\Benefit::class, 50)->create();
$this->json('get', '/api/benefits')->assertStatus(200);
}
}
phpunit.xml setup is
<env name="APP_ENV" value="testing"/>
<env name="DB_CONNECTION" value="sqlite"/>
<env name="DB_DATABASE" value=":memory:"/>
config/database simply
'sqlite' => [
'driver' => 'sqlite',
'database' => env('DB_DATABASE', database_path('database.sqlite')),
'prefix' => '',
],
Can anyone see anything glaring ? How do I even debug what is wrong as nothing is in the logs at all ?
Please or to participate in this conversation.