Deprecate Enhanced navigation feature integration #85
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
workflow_dispatch: # Can manually run from any branch | |
push: | |
branches: | |
- main | |
pull_request: | |
# Cancel previous jobs before starting this one. Works on pull_request event only due to use of head_ref. | |
# https://docs.github.com/en/actions/using-jobs/using-concurrency | |
concurrency: | |
group: ${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
jobs: | |
php-tests: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
include: | |
- php: '8.3' | |
os: 'ubuntu-24.04' | |
- php: '8.2' | |
os: 'ubuntu-20.04' | |
- php: '8.1' | |
os: 'ubuntu-latest' | |
- php: '8.0' | |
os: 'ubuntu-20.04' | |
- php: '7.4' | |
os: 'ubuntu-20.04' | |
fail-fast: false | |
env: | |
COVERAGE_CACHE_PATH: phpunit-coverage-cache | |
PHP_VERSION: ${{ matrix.php }} | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | |
- name: Switch to PHP ${{ env.PHP_VERSION }} | |
run: | | |
sudo update-alternatives --set php /usr/bin/php$PHP_VERSION | |
sudo update-alternatives --set phar /usr/bin/phar$PHP_VERSION | |
sudo update-alternatives --set phar.phar /usr/bin/phar.phar$PHP_VERSION | |
sudo update-alternatives --set phpize /usr/bin/phpize$PHP_VERSION | |
sudo update-alternatives --set php-config /usr/bin/php-config$PHP_VERSION | |
- name: Setup INI file | |
run: | | |
PHP_INI_LOCATION="$(php -r 'echo php_ini_loaded_file();')" | |
if [[ -z "$PHP_INI_LOCATION" || ! -f "$PHP_INI_LOCATION" ]]; then | |
echo 'Unable to determine php.ini location' | |
exit 1 | |
fi | |
echo "zend.assertions=1" | sudo tee -a "$PHP_INI_LOCATION" | |
- name: Get Composer Cache Directory | |
id: composer-cache | |
run: | | |
echo "::set-output name=dir::$(composer config cache-files-dir)" | |
- uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2 | |
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-ansi --no-interaction --no-scripts --no-progress --prefer-dist | |
- name: Check platform requirements on PHP ${{ env.PHP_VERSION }} | |
run: | | |
composer check-platform-reqs --no-dev --no-interaction --no-scripts | |
- name: Execute tests via PHPUnit | |
env: | |
DB_CONNECTION: sqlite | |
DB_DATABASE: database/database.sqlite | |
run: | | |
vendor/bin/phpunit --order-by="random" --coverage-text |