384 Laravel 6 changes (#385)

* 384 Laravel 6 changes

* Library versions

* Update package versions

* Add keyType to models

* Remove unused dependencies

* StyleCI fixes

* Fix models for test

* Fix tests output and update test runner

* Unused imports

* Update exceptions handler

* Fix login page
This commit is contained in:
Nabeel S
2019-09-13 08:05:02 -04:00
committed by GitHub
parent 7a76ac4226
commit 23eb9dcbda
48 changed files with 935 additions and 829 deletions

View File

@@ -7,14 +7,15 @@ use GuzzleHttp\Handler\MockHandler;
use GuzzleHttp\HandlerStack;
use GuzzleHttp\Psr7\Response;
use Illuminate\Routing\Middleware\ThrottleRequests;
use Illuminate\Support\Facades\Artisan;
use Illuminate\Support\Facades\Mail;
use Tests\CreatesApplication;
use Tests\TestData;
/**
* Class TestCase
*/
class TestCase extends Illuminate\Foundation\Testing\TestCase
{
use TestData;
use CreatesApplication;
/**
* The base URL to use while testing the application.
@@ -45,8 +46,10 @@ class TestCase extends Illuminate\Foundation\Testing\TestCase
ThrottleRequests::class
);
Mail::fake();
Artisan::call('database:create', ['--reset' => true]);
Artisan::call('migrate:refresh', ['--env' => 'unittest']);
Artisan::call('migrate:refresh', ['--env' => 'testing']);
}
public function tearDown() : void
@@ -54,18 +57,6 @@ class TestCase extends Illuminate\Foundation\Testing\TestCase
parent::tearDown();
}
/**
* Creates the application. Required to be implemented
*
* @return \Illuminate\Foundation\Application
*/
public function createApplication()
{
$app = require __DIR__.'/../bootstrap/app.php';
$app->make(Illuminate\Contracts\Console\Kernel::class)->bootstrap();
return $app;
}
/**
* @param $user
* @param array $headers