Skip to content

Commit

Permalink
switch to github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
maglnet committed Aug 11, 2021
1 parent 07d9145 commit f169977
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 31 deletions.
50 changes: 50 additions & 0 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: unit-tests

on: [push]

jobs:
phpunit:
name: "PHPUnit tests"

runs-on: ${{ matrix.operating-system }}

strategy:
matrix:
php-version:
- "7.3"
- "7.4"
- "8.0"
operating-system:
- "ubuntu-latest"

steps:
- name: "Checkout"
uses: "actions/checkout@v2"

- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
with:
coverage: "pcov"
php-version: "${{ matrix.php-version }}"
ini-values: memory_limit=-1

- name: Get Composer cache directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-dir)"

- name: Cache dependencies
uses: actions/cache@v2
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: composer-${{ runner.os }}-${{ matrix.php-version }}-${{ hashFiles('composer.*') }}
restore-keys: |
composer-${{ runner.os }}-${{ matrix.php-version }}-${{ hashFiles('composer.*') }}-
composer-${{ runner.os }}-${{ matrix.php-version }}-
composer-${{ runner.os }}-
composer-
- name: "Install dependencies"
run: "composer update --no-interaction --no-progress --no-suggest"

- name: "Tests"
run: "vendor/bin/phpunit -c tests"

8 changes: 0 additions & 8 deletions .scrutinizer.yml

This file was deleted.

23 changes: 0 additions & 23 deletions .travis.yml

This file was deleted.

0 comments on commit f169977

Please sign in to comment.