You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running PHPUnit and having a class extending from TestCase and using use RefreshDatabase; for migrations, it returns an error:
Example class:
<?php
namespace Tests\Feature;
use Tests\TestCase;
use Illuminate\Foundation\Testing\RefreshDatabase;
class ExampleTest extends TestCase
{
use RefreshDatabase;
/**
* A basic test example.
*
* @return void
*/
public function testBasicTest()
{
$response = $this->get('/');
$response->assertStatus(200);
}
}
Error:
Illuminate\Database\QueryException: could not find driver (SQL: SHOW FULL TABLES WHERE table_type = 'BASE TABLE')
Is there something to add to the config.yml file?
The text was updated successfully, but these errors were encountered:
Same problem is there for me, in the pipeline config I install sqlite with sudo apt install -y libsqlite3-dev zlib1g-dev . Then, migration is successful, while the tests are failing due to error: could not find the driver (same as explained above). Could anyone solve the issue so far?
When running PHPUnit and having a class extending from
TestCase
and usinguse RefreshDatabase;
for migrations, it returns an error:Example class:
Error:
Illuminate\Database\QueryException: could not find driver (SQL: SHOW FULL TABLES WHERE table_type = 'BASE TABLE')
Is there something to add to the config.yml file?
The text was updated successfully, but these errors were encountered: