Skip to content

Commit

Permalink
Upgrade action steps and remove unused coverage for actions speedup
Browse files Browse the repository at this point in the history
  • Loading branch information
SerafimArts committed Feb 18, 2024
1 parent 941475b commit 1b0f62a
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,35 +25,28 @@ jobs:
git config --global core.autocrlf false
git config --global core.eol lf
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Setup PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
tools: composer:v2
extensions: mbstring
coverage: pcov
ini-values: "memory_limit=-1"
- name: Get Composer Cache Directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
- name: Restore Composer Cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-${{ matrix.php }}-composer-${{ hashFiles('**/composer.json') }}
restore-keys: ${{ runner.os }}-${{ matrix.php }}-composer-
- name: Install Dependencies (PHP Stable)
uses: nick-invision/retry@v2
uses: nick-invision/retry@v3
with:
timeout_minutes: 5
max_attempts: 5
command: composer update --${{ matrix.stability }} --prefer-dist --no-interaction --no-progress
- name: Execute Tests
run: vendor/bin/phpunit --colors=always --coverage-clover=coverage.xml
- name: Upload Coverage
if: matrix.os == 'ubuntu-latest'
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml
run: vendor/bin/phpunit --colors=always

0 comments on commit 1b0f62a

Please sign in to comment.