diff --git a/tests/Integration/SQLLoaderIntegrationTest.php b/tests/Integration/SQLLoaderIntegrationTest.php new file mode 100644 index 0000000..5b0c663 --- /dev/null +++ b/tests/Integration/SQLLoaderIntegrationTest.php @@ -0,0 +1,17 @@ +count(); + + SQLLoader::make() + ->inFile(__DIR__.'/../data/users.dat') + ->withHeaders() + ->into('users') + ->execute(); + + assertDatabaseCount('users', $count + 4); +})->skip(! file_exists('/usr/local/bin/sqlldr'), 'This test is skipped because it requires SQLLDR binary.'); diff --git a/tests/Pest.php b/tests/Pest.php index dfb4772..c408ce4 100644 --- a/tests/Pest.php +++ b/tests/Pest.php @@ -14,7 +14,7 @@ use Illuminate\Foundation\Testing\RefreshDatabase; use Yajra\SQLLoader\Tests\TestCase; -uses(TestCase::class, RefreshDatabase::class)->in('Feature'); +uses(TestCase::class, RefreshDatabase::class)->in('Feature', 'Integration'); /* |--------------------------------------------------------------------------