Skip to content

Adds number parsing to variables that comes from .env #118

Adds number parsing to variables that comes from .env

Adds number parsing to variables that comes from .env #118

Workflow file for this run

name: PHPUnit tests
on:
push:
pull_request:
release:
types:
- published
jobs:
php-tests:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
php: [8.0, 8.1, 8.2, 8.3]
laravel: [9.*, 10.*, 11.*]
os: [ubuntu-latest]
coverage: [none]
include:
- php: 8.3
laravel: 11.*
os: ubuntu-latest
coverage: xdebug
exclude:
- php: 8.0
laravel: 10.*
- php: 8.0
laravel: 11.*
- php: 8.1
laravel: 11.*
name: '[P${{ matrix.php }}] [L${{ matrix.laravel }}] [${{ matrix.coverage }}]'
steps:
- name: Checkout code
uses: actions/checkout@v1
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: mbstring json openssl
coverage: ${{ matrix.coverage }}
ini-values: memory_limit=-1
- name: Get composer cache directory
id: composer-cache
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache dependencies
uses: actions/cache@v3
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: "php-${{ matrix.php }}-laravel-${{ matrix.laravel }}-${{ hashFiles('**/composer.json') }}"
restore-keys: "php-${{ matrix.php }}-laravel-${{ matrix.laravel }}-${{ hashFiles('**/composer.json') }}"
- name: Install dependencies
run: |
composer require "illuminate/contracts:${{ matrix.laravel }}" --no-interaction --no-progress --no-update
composer update --no-progress --prefer-dist --no-interaction
- name: Execute tests
run: composer test:ci
- name: Upload coverage
uses: codecov/codecov-action@v1
if: matrix.coverage == 'xdebug'
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
yml: ./codecov.yml