Skip to content

Removing schema and routes check when request comes from web and hotReload is set to false to avoid unnecessary use of resources. #228

Removing schema and routes check when request comes from web and hotReload is set to false to avoid unnecessary use of resources.

Removing schema and routes check when request comes from web and hotReload is set to false to avoid unnecessary use of resources. #228

Workflow file for this run

name: Pull Request
on:
pull_request:
jobs:
build:
name: PHP ${{ matrix.php-versions }} Test
runs-on: ubuntu-latest
strategy:
matrix:
operating-system: [ ubuntu-20.04 ]
php-versions: ['8.0', '8.1', '8.2']
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
extensions: mbstring, intl, xdebug
- name: PHP Version
run: php -v
- name: Install dependencies
if: steps.composer-cache.outputs.cache-hit != 'true'
run: |
composer self-update
composer validate
composer install --prefer-dist --no-progress
- name: Test Suite (8.0 only)
if: ${{ matrix.php-versions != '8.2' }}
run: |
composer test
echo ${{ matrix.php-versions }}
- name: Test Suite + Static Analysis (8.1 only)
if: ${{ matrix.php-versions == '8.2' }}
env:
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
composer analyze
echo ${{ matrix.php-versions }}
- name: Upload coverage results to Coveralls (8.1 only)
if: ${{ matrix.php-versions == '8.2' }}
env:
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
composer global require php-coveralls/php-coveralls
export CODECOVERAGE=1 && vendor/bin/phpunit --verbose --coverage-clover=clover.xml
php-coveralls --coverage_clover=clover.xml -v
#
# CakePHP version compatability
#
compatibility:
name: CakePHP ${{ matrix.version }} Test
runs-on: ubuntu-latest
strategy:
matrix:
version: ['~4.2.0', '~4.3.0', '~4.4', '~4.5']
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.1'
extensions: mbstring, intl
- name: PHP Version
run: php -v
- name: CakePHP ${{matrix.version}} Compatability
run: |
composer self-update
rm -rf composer.lock
composer require cakephp/cakephp:${{matrix.version}} --no-update
composer install --prefer-dist --no-progress
composer test