Skip to content

Rebalanced workflow tests. #5

Rebalanced workflow tests.

Rebalanced workflow tests. #5

# This action is used for Vortex maintenance. It will not be used in the scaffolded project.
name: Vortex - Test installer
on:
push:
branches:
- main
pull_request:
branches:
- main
- 'feature/**'
jobs:
vortex-test-installer:
runs-on: ubuntu-latest
strategy:
matrix:
php-versions: ['8.1', '8.2', '8.3']
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
coverage: pcov
ini-values: pcov.directory=.
- name: Install dependencies
run: composer install
working-directory: .vortex/installer
- name: Check coding standards
run: composer lint
working-directory: .vortex/installer
- name: Run tests
run: composer test
working-directory: .vortex/installer
- name: Upload coverage report as an artifact
uses: actions/upload-artifact@v4
with:
name: ${{github.job}}-code-coverage-report-${{ matrix.php-versions }}
path: .vortex/installer/.coverage-html
- name: Upload coverage report to Codecov
uses: codecov/codecov-action@v5
with:
files: .vortex/installer/cobertura.xml
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}
# Smoke test for PHAR.
- name: Build PHAR
run: composer build
working-directory: .vortex/installer
- name: Test PHAR
run: .vortex/installer/build/installer --quiet || exit 1