Main #222
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Main | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "0 0 * * *" | |
push: | |
branches: | |
- main | |
permissions: | |
actions: write | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Cancel Previous Runs | |
uses: styfle/[email protected] | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
- name: Setup PHP with PECL extension | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: '8.3' | |
extensions: imagick, swoole | |
tools: composer:2.7 | |
coverage: pcov | |
- name: Install dependencies | |
uses: ramsey/composer-install@v2 | |
- name: Setup env | |
run: | | |
cp .env.example .env | |
php artisan key:generate | |
- name: Run tests | |
run: vendor/bin/phpunit | |
- uses: qltyai/qlty-action/coverage@main | |
with: | |
coverage-token: ${{ secrets.QLTY_COVERAGE_TOKEN }} | |
file: coverage/clover.xml |