-
Notifications
You must be signed in to change notification settings - Fork 1
25 lines (25 loc) · 1.01 KB
/
tests.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
name: tests
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: 'recursive'
- name: Build the stack
run: docker/env dev on
- name: Validate composer.lock
run: docker/run dev:php composer validate --strict --no-cache
- name: Install dependencies
run: cp .env.testing .env && docker/run dev:php composer install
- name: Setup env
run: docker/run dev:php ./artisan storage:link && docker/run dev:php ./artisan migrate --env=testing
- name: Execute lint
run: docker/run dev:php vendor/bin/php-cs-fixer fix --no-interaction --dry-run --diff --using-cache=no -v
- name: Execute tests
run: XDEBUG_MODE=coverage docker/run -e XDEBUG_MODE dev:php vendor/bin/phpunit --verbose --coverage-text --coverage-clover=build/logs/clover.xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
with:
file: build/logs/clover.xml