mirror of https://github.com/kcal-app/kcal.git
Use MySQL for tests in CI (#40)
This commit is contained in:
parent
6bc18c48a8
commit
0e8eba8b91
7
.env.ci
7
.env.ci
|
@ -7,7 +7,12 @@ APP_URL=http://localhost
|
|||
LOG_CHANNEL=stack
|
||||
LOG_LEVEL=debug
|
||||
|
||||
DB_CONNECTION=sqlite
|
||||
DB_CONNECTION=mysql
|
||||
DB_HOST=127.0.0.1
|
||||
DB_PORT=3306
|
||||
DB_DATABASE=kcal
|
||||
DB_USERNAME=root
|
||||
DB_PASSWORD=root
|
||||
|
||||
SCOUT_DRIVER=elastic
|
||||
ELASTIC_HOST=localhost:9200
|
||||
|
|
|
@ -10,6 +10,10 @@ jobs:
|
|||
test:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: mirromutth/mysql-action@v1.1
|
||||
with:
|
||||
mysql database: kcal
|
||||
mysql root password: root
|
||||
- uses: shivammathur/setup-php@v2
|
||||
with:
|
||||
php-version: '8.0'
|
||||
|
@ -41,7 +45,7 @@ jobs:
|
|||
php -r "file_exists('.env') || copy('.env.ci', '.env');"
|
||||
php artisan key:generate
|
||||
- name: Run tests
|
||||
run: vendor/bin/paratest --coverage-clover build/logs/clover.xml
|
||||
run: php artisan test --parallel --recreate-databases --coverage-clover build/logs/clover.xml
|
||||
- name: Upload coverage results to Coveralls
|
||||
env:
|
||||
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
|
Loading…
Reference in New Issue