Skip to content

GH Actions: turn on tests against PHP 8.1 & various other tweaks #210

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Aug 13, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 11 additions & 26 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ on:
branches:
- 5.x
pull_request:
# Allow manually triggering the workflow.
workflow_dispatch:
name: Qa workflow
env:
phiveGPGKeys: 4AA394086372C20A,D2CCAC42F6295E7D,E82B2FB314E9906E,8A03EA3B385DBAA1,D0254321FB74703A
Expand Down Expand Up @@ -52,12 +54,14 @@ jobs:
name: Unit tests for PHP version ${{ matrix.php-versions }} on ${{ matrix.operating-system }}
runs-on: ${{ matrix.operating-system }}
strategy:
fail-fast: false
matrix:
operating-system:
- ubuntu-latest
- windows-latest
- macOS-latest
php-versions: ['7.2', '7.3', '7.4', '8.0']
php-versions: ['7.2', '7.3', '7.4', '8.0', '8.1']

env:
extensions: mbstring
key: cache-v1 # can be any string, change to clear the extension cache.
Expand Down Expand Up @@ -102,22 +106,12 @@ jobs:
GITHUB_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: phive --no-progress install --copy --trust-gpg-keys ${{ env.phiveGPGKeys }} phpunit:^8.5

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

- name: Cache dependencies
uses: actions/cache@v2.1.6
- name: Install Composer dependencies & cache dependencies
uses: "ramsey/composer-install@v1"
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-

- name: Install dependencies
run: composer install --no-interaction --prefer-dist --optimize-autoloader
composer-options: --optimize-autoloader

- name: Run PHPUnit
continue-on-error: true
run: php tools/phpunit

codestyle:
Expand Down Expand Up @@ -198,19 +192,10 @@ jobs:
# tools: psalm
# ini-values: memory_limit=2G, display_errors=On, error_reporting=-1
#
# - name: Get composer cache directory
# id: composer-cache
# run: echo "::set-output name=dir::$(composer config cache-files-dir)"
#
# - name: Cache dependencies
# uses: actions/cache@v2.1.6
# - name: Install Composer dependencies & cache dependencies
# uses: "ramsey/composer-install@v1"
# with:
# path: ${{ steps.composer-cache.outputs.dir }}
# key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
# restore-keys: ${{ runner.os }}-composer-
#
# - name: Install dependencies
# run: composer install --no-interaction --prefer-dist --optimize-autoloader
# composer-options: --optimize-autoloader
#
# - name: Run psalm
# run: psalm --output-format=github
Expand Down
2 changes: 1 addition & 1 deletion phive.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<phive xmlns="https://phar.io/phive">
<phar name="phpunit" version="^9.2" installed="9.4.2" location="./tools/phpunit" copy="true"/>
<phar name="phpunit" version="^9.5" installed="9.5.8" location="./tools/phpunit" copy="true"/>
<phar name="phpbench" version="^0.16.9" installed="0.16.9" location="./tools/phpbench" copy="true"/>
<phar name="scrutinizer-ci/ocular" version="^1.6.0" installed="1.6.0" location="./tools/ocular" copy="true" force-accept-unsigned="true"/>
</phive>