more fixes for travis

This commit is contained in:
Nabeel Shahzad 2017-06-08 22:50:22 -05:00
parent 616f44f9c5
commit 5e323c3310
5 changed files with 25 additions and 28 deletions

11
.env.travis Normal file
View File

@ -0,0 +1,11 @@
APP_ENV=testing
APP_KEY=base64:ve66Z5Kt/zTN3p++0zOPu854PHfZkwJE5VuoFAlzHtI=
APP_DEBUG=true
APP_LOG_LEVEL=debug
APP_URL=http://localhost
DB_CONNECTION=testing
CACHE_DRIVER=array
SESSION_DRIVER=array
QUEUE_DRIVER=sync

View File

@ -5,5 +5,11 @@ php:
- '7.1'
- hhvm
install:
- make
before_script:
- cp .env.travis .env
# - mysql -e 'create database phpvms_test;'
- composer self-update
- make build
script:
- vendor/bin/phpunit

View File

@ -9,19 +9,18 @@ all: build
build:
composer install
make db
composer install --no-interaction
@make db
install:
echo ""
db:
mkdir -p tmp/
sqlite3 tmp/database.sqlite ""
# sqlite3 database/testing.sqlite ""
php artisan migrate
reset-db:
rm tmp/database.sqlite
rm database/testing.sqlite
make db
schema:

View File

@ -46,9 +46,9 @@ return [
'connections' => [
'sqlite' => [
'testing' => [
'driver' => 'sqlite',
'database' => env('DB_DATABASE', base_path('tmp/database.sqlite')),
'database' => database_path('testing.sqlite'),
'prefix' => '',
],

View File

@ -1,19 +0,0 @@
<?php
use Illuminate\Foundation\Testing\WithoutMiddleware;
use Illuminate\Foundation\Testing\DatabaseMigrations;
use Illuminate\Foundation\Testing\DatabaseTransactions;
class ExampleTest extends TestCase
{
/**
* A basic functional test example.
*
* @return void
*/
public function testBasicExample()
{
$this->visit('/')
->see('Laravel');
}
}