feat: 🎸 Support float precision #85
Workflow file for this run
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: CI | |
on: [push] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
services: | |
mysql: | |
image: mysql:8.0 | |
ports: | |
- '3306:3306' | |
env: | |
MYSQL_DATABASE: testing | |
MYSQL_USER: testing | |
MYSQL_PASSWORD: testing | |
MYSQL_ROOT_PASSWORD: testing | |
options: >- | |
--health-cmd="mysqladmin ping" | |
--health-interval=10s | |
--health-timeout=30s | |
--health-retries=5 | |
mariadb: | |
image: mariadb:10.0 | |
ports: | |
- '3307:3306' | |
env: | |
MYSQL_DATABASE: testing | |
MYSQL_USER: testing | |
MYSQL_PASSWORD: testing | |
MYSQL_ROOT_PASSWORD: testing | |
options: >- | |
--health-cmd="mysqladmin ping" | |
--health-interval=10s | |
--health-timeout=30s | |
--health-retries=5 | |
postgres: | |
image: postgres:13.3 | |
ports: | |
- '5432:5432' | |
env: | |
POSTGRES_DB: testing | |
POSTGRES_USER: testing | |
POSTGRES_PASSWORD: testing | |
options: >- | |
--health-cmd=pg_isready | |
--health-interval=10s | |
--health-timeout=30s | |
--health-retries=5 | |
strategy: | |
matrix: | |
php: ['8.0', 8.1, 8.2] | |
lib: | |
- { laravel: ^11.0 } | |
- { laravel: ^10.0 } | |
- { laravel: ^9.0 } | |
exclude: | |
- { php: 8.0, lib: { laravel: ^10.0 } } | |
- { php: 8.0, lib: { laravel: ^11.0 } } | |
- { php: 8.1, lib: { laravel: ^11.0 } } | |
include: | |
- { lib: { laravel: ^9.0 }, phpstan: 1 } | |
- { lib: { laravel: ^10.0 }, phpstan: 1 } | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php }} | |
coverage: xdebug | |
- name: Remove impossible dependencies | |
if: ${{ matrix.phpstan != 1 }} | |
run: composer remove nunomaduro/larastan --dev --no-update | |
- name: Adjust Package Versions | |
run: | | |
composer require "laravel/framework:${{ matrix.lib.laravel }}" --dev --no-update | |
composer update | |
- name: Prepare Coverage Directory | |
run: mkdir -p build/logs | |
- name: PHP-CS-Fixer | |
run: composer cs | |
- name: PHPStan | |
if: ${{ matrix.phpstan == 1 }} | |
run: composer phpstan | |
- name: Test | |
run: composer test -- --testdox --coverage-clover build/logs/clover.xml | |
env: | |
PG_HOST: 127.0.0.1 | |
MY_HOST: 127.0.0.1 | |
MA_HOST: 127.0.0.1 | |
MA_PORT: '3307' | |
- name: Upload Coverage | |
uses: nick-invision/retry@v2 | |
env: | |
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
COVERALLS_PARALLEL: 'true' | |
COVERALLS_FLAG_NAME: "laravel:${{ matrix.lib.laravel }} php:${{ matrix.php }}" | |
with: | |
timeout_minutes: 1 | |
max_attempts: 3 | |
command: | | |
composer global require php-coveralls/php-coveralls | |
php-coveralls --coverage_clover=build/logs/clover.xml -v | |
coverage-aggregation: | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Aggregate Coverage | |
uses: coverallsapp/github-action@master | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
parallel-finished: true |