Skip to content

Commit

Permalink
CI: update
Browse files Browse the repository at this point in the history
  • Loading branch information
f3l1x committed Jan 4, 2021
1 parent d98ffd3 commit df9b1ed
Showing 1 changed file with 25 additions and 9 deletions.
34 changes: 25 additions & 9 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ env:
cache-version: "1"
composer-version: "v1"
composer-install: "composer update --no-interaction --no-progress --no-suggest --prefer-dist --prefer-stable"
coverage: "none"

jobs:
qa:
Expand Down Expand Up @@ -51,7 +52,8 @@ jobs:
with:
php-version: "${{ matrix.php-version }}"
extensions: "${{ env.extensions }}"
tools: "composer:${{ env.composer-version }} "
tools: "composer:${{ env.composer-version }}, cs2pr"
coverage: "${{ env.coverage }}"

- name: "Setup problem matchers for PHP"
run: 'echo "::add-matcher::${{ runner.tool_cache }}/php.json"'
Expand Down Expand Up @@ -110,7 +112,8 @@ jobs:
with:
php-version: "${{ matrix.php-version }}"
extensions: "${{ env.extensions }}"
tools: "composer:${{ env.composer-version }} "
tools: "composer:${{ env.composer-version }}"
coverage: "${{ env.coverage }}"

- name: "Setup problem matchers for PHP"
run: 'echo "::add-matcher::${{ runner.tool_cache }}/php.json"'
Expand Down Expand Up @@ -142,12 +145,12 @@ jobs:
operating-system: ["ubuntu-latest"]
composer-args: [ "" ]
include:
- php-version: "7.4"
- php-version: "7.2"
operating-system: "ubuntu-latest"
composer-args: "--prefer-lowest"
- php-version: "8.0"
operating-system: "ubuntu-latest"
composer-args: "--ignore-platform-reqs"
composer-args: ""
fail-fast: false

continue-on-error: "${{ matrix.php-version == '8.0' }}"
Expand Down Expand Up @@ -176,7 +179,8 @@ jobs:
with:
php-version: "${{ matrix.php-version }}"
extensions: "${{ env.extensions }}"
tools: "composer:${{ env.composer-version }} "
tools: "composer:${{ env.composer-version }}"
coverage: "${{ env.coverage }}"

- name: "Setup problem matchers for PHP"
run: 'echo "::add-matcher::${{ runner.tool_cache }}/php.json"'
Expand All @@ -195,12 +199,16 @@ jobs:
- name: "Install dependencies"
run: "${{ env.composer-install }} ${{ matrix.composer-args }}"

- name: "Setup problem matchers for PHPUnit"
run: 'echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"'

- name: "Tests"
run: "make tests"

- name: "Upload test output"
if: ${{ failure() }}
uses: actions/upload-artifact@v2
with:
name: output
path: tests/**/output

tests-code-coverage:
name: "Tests with code coverage"
runs-on: "${{ matrix.operating-system }}"
Expand Down Expand Up @@ -237,7 +245,8 @@ jobs:
with:
php-version: "${{ matrix.php-version }}"
extensions: "${{ env.extensions }}"
tools: "composer:${{ env.composer-version }} "
tools: "composer:${{ env.composer-version }}"
coverage: "${{ env.coverage }}"

- name: "Setup problem matchers for PHP"
run: 'echo "::add-matcher::${{ runner.tool_cache }}/php.json"'
Expand All @@ -259,6 +268,13 @@ jobs:
- name: "Tests"
run: "make coverage-clover"

- name: "Upload test output"
if: ${{ failure() }}
uses: actions/upload-artifact@v2
with:
name: output
path: tests/**/output

- name: "Coveralls.io"
env:
CI_NAME: github
Expand Down

0 comments on commit df9b1ed

Please sign in to comment.