-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: bump github actions and align with cas-bundle
- Loading branch information
Showing
3 changed files
with
26 additions
and
38 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,60 +1,50 @@ | ||
# https://help.github.com/en/categories/automating-your-workflow-with-github-actions | ||
|
||
on: | ||
- pull_request | ||
- push | ||
push: | ||
pull_request: | ||
|
||
name: "Continuous Integration" | ||
|
||
jobs: | ||
run: | ||
name: "Grumphp" | ||
supported-versions-matrix: | ||
name: Supported Versions Matrix | ||
runs-on: ubuntu-latest | ||
outputs: | ||
version: ${{ steps.supported-versions-matrix.outputs.version }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- id: supported-versions-matrix | ||
uses: WyriHaximus/github-action-composer-php-versions-in-range@v1 | ||
tests: | ||
name: "Unit Tests" | ||
runs-on: ${{ matrix.operating-system }} | ||
needs: | ||
- supported-versions-matrix | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
operating-system: [ubuntu-latest, windows-latest, macOS-latest] | ||
php-versions: ["8.1"] | ||
|
||
php: ${{ fromJson(needs.supported-versions-matrix.outputs.version) }} | ||
steps: | ||
- name: Set git to use LF | ||
run: | | ||
git config --global core.autocrlf false | ||
git config --global core.eol lf | ||
- name: Checkout | ||
uses: actions/checkout@master | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install PHP | ||
uses: shivammathur/setup-php@master | ||
with: | ||
php-version: ${{ matrix.php-versions }} | ||
extensions: xdebug,mbstring | ||
|
||
- 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@v3 | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
path: ${{ steps.composer-cache.outputs.dir }} | ||
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} | ||
restore-keys: ${{ runner.os }}-composer- | ||
php-version: ${{ matrix.php }} | ||
coverage: pcov | ||
|
||
- name: Install dependencies | ||
run: composer install --no-progress --no-suggest --prefer-dist --optimize-autoloader | ||
uses: ramsey/composer-install@v2 | ||
|
||
- name: Run Grumphp | ||
run: vendor/bin/grumphp run | ||
env: | ||
STRYKER_DASHBOARD_API_KEY: ${{ secrets.STRYKER_DASHBOARD_API_KEY }} | ||
|
||
- name: Send PSALM data | ||
run: vendor/bin/psalm --shepherd --stats | ||
continue-on-error: true | ||
|
||
- name: Infection score report | ||
run: | | ||
vendor/bin/infection run -j 2 | ||
continue-on-error: true | ||
PHP_CS_FIXER_IGNORE_ENV: 1 | ||
run: vendor/bin/grumphp 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
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