Install svn before deployment. #601
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
name: Cyr2Lat CI | |
on: [ push, pull_request ] | |
jobs: | |
cs_and_tests: | |
strategy: | |
matrix: | |
os: [ ubuntu-latest ] | |
php-version: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ] | |
runs-on: ${{ matrix.os }} | |
name: PHP ${{ matrix.php-version }} on ${{ matrix.os }} | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php-version }} | |
extensions: json, mysqli, mbstring, zip | |
- name: Install dependencies with caching | |
uses: ramsey/composer-install@v3 | |
- name: Run code sniffer | |
run: composer phpcs | |
- name: Run PHPUnit tests | |
if: ${{ matrix.php-version != '8.4' }} | |
run: vendor/bin/phpunit | |
- name: Run PHPUnit tests with coverage | |
if: ${{ matrix.php-version == '8.4' }} | |
run: vendor/bin/phpunit --coverage-clover coverage.xml | |
- name: Run Coveralls for PHPUnit tests | |
if: ${{ matrix.php-version == '8.4' }} | |
env: | |
COVERALLS_RUN_LOCALLY: true | |
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
run: vendor/bin/php-coveralls -v | |
- name: Run ESLint, JEST with coverage and Coveralls | |
if: ${{ matrix.php-version == '8.4' }} | |
env: | |
COVERALLS_RUN_LOCALLY: true | |
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
run: | | |
corepack enable | |
yarn set version stable | |
yarn | |
yarn dev | |
yarn lint | |
yarn run coveralls |