Skip to content

Commit

Permalink
Merge pull request #2 from MekDrop/ci-tests
Browse files Browse the repository at this point in the history
Added github-ci tests workflow
  • Loading branch information
MekDrop authored Mar 26, 2022
2 parents 521b4d6 + def4171 commit 297048f
Showing 1 changed file with 54 additions and 0 deletions.
54 changes: 54 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Tests

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
run:
runs-on: ${{ matrix.os }}
strategy:
max-parallel: 2
matrix:
php:
- 5.4
- 5.5
- 5.6
- 7.0
- 7.1
- 7.2
- 7.3
- 7.4
# - 8.0
# - 8.1
os:
- ubuntu-latest
- windows-latest
- macOS-latest
name: PHP ${{ matrix.php }}; ${{ matrix.os }}
steps:
- name: Setup PHP
uses: shivammathur/setup-php@master
with:
php-version: ${{ matrix.php }}
extensions: curl, json, mbstring, pcre
ini-values: memory_limit=512M
tools: composer:v2
- name: Check PHP Version
run: php -v
- name: Checkout
uses: actions/checkout@master
- name: Composer install without dev
run: composer install --no-progress --no-dev --prefer-dist --optimize-autoloader
- name: Composer install with dev
run: composer install --no-progress --prefer-dist --optimize-autoloader
- name: PHPUnit (not windows)
run: ./vendor/bin/phpunit tests/
if: matrix.os != 'windows-latest'
- name: PHPUnit (windows)
run: .\vendor\bin\phpunit tests/
if: matrix.os == 'windows-latest'

0 comments on commit 297048f

Please sign in to comment.