1
0
mirror of https://github.com/freescout-helpdesk/freescout.git synced 2025-01-31 12:01:39 +01:00

Travis Testing

This commit is contained in:
FreeScout 2018-07-23 23:06:59 -07:00
parent 2273b3308d
commit 0402697b1e
5 changed files with 36 additions and 21 deletions

10
.env.travis Normal file
View File

@ -0,0 +1,10 @@
APP_ENV=testing
APP_KEY=SomeRandomString7
DB_CONNECTION=testing
DB_TEST_USERNAME=root
DB_TEST_PASSWORD=
CACHE_DRIVER=array
SESSION_DRIVER=array
QUEUE_DRIVER=sync

13
.travis.yml Normal file
View File

@ -0,0 +1,13 @@
language: php
php:
- 7.0
- 7.1
- 7.2
before_script:
- cp .env.travis .env
- mysql -e 'create database homestead_test;'
script:
- vendor/bin/phpunit

View File

@ -54,6 +54,18 @@ return [
'engine' => null,
],
'testing' => [
'driver' => 'mysql',
'host' => env('DB_TEST_HOST', 'localhost'),
'database' => env('DB_TEST_DATABASE', 'homestead_test'),
'username' => env('DB_TEST_USERNAME', 'homestead'),
'password' => env('DB_TEST_PASSWORD', 'secret'),
'charset' => 'utf8mb4',
'collation' => 'utf8mb4_unicode_ci',
'prefix' => '',
'strict' => false,
],
'pgsql' => [
'driver' => 'pgsql',
'host' => env('DB_HOST', '127.0.0.1'),

View File

@ -24,6 +24,7 @@
</filter>
<php>
<env name="APP_ENV" value="testing"/>
<env name="DB_CONNECTION" value="testing"/>
<env name="CACHE_DRIVER" value="array"/>
<env name="SESSION_DRIVER" value="array"/>
<env name="QUEUE_DRIVER" value="sync"/>

View File

@ -1,21 +0,0 @@
<?php
namespace Tests\Feature;
use Tests\TestCase;
use Illuminate\Foundation\Testing\RefreshDatabase;
class ExampleTest extends TestCase
{
/**
* A basic test example.
*
* @return void
*/
public function testBasicTest()
{
$response = $this->get('/');
$response->assertStatus(200);
}
}