Skip to content

Update phpunit/phpunit requirement from ^9.5 to ^11.4 #13

Update phpunit/phpunit requirement from ^9.5 to ^11.4

Update phpunit/phpunit requirement from ^9.5 to ^11.4 #13

Workflow file for this run

name: PHPUnit Tests
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: read
# Cancels all previous workflow runs for pull requests that have not completed.
concurrency:
# The concurrency group contains the workflow name and the branch name for pull requests
# or the commit hash for any other events.
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
cancel-in-progress: true
jobs:
run:
name: PHP ${{ matrix.php }} Test
runs-on: ${{ matrix.os }}
timeout-minutes: 20
if: ${{ github.repository == 'CSoellinger/silverstripe-limit-characters-with-html' }}
strategy:
fail-fast: false
matrix:
php: [ '7.4', '8.0', '8.1', '8.2' ]
os: [ ubuntu-latest ]
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
coverage: none
tools: phpunit:9.5
- name: Validate composer.json and composer.lock
run: composer validate --strict
# Since Composer dependencies are installed using `composer update` and no lock file is in version control,
# passing a custom cache suffix ensures that the cache is flushed at least once per week.
- name: Install Composer dependencies
uses: ramsey/composer-install@v2 # v2.2.0
with:
custom-cache-suffix: $(/bin/date -u --date='last Mon' "+%F")
# - name: General debug information
# run: |
# curl --version
# git --version
# composer --version
# php --version
# locale -a
- name: Run test suite
run: composer run-script test