Skip to content

Commit dd447a2

Browse files
committed
Replace travis-ci by github actions
Bump minimum PHP to 7.3 according to LTS. Add PHP 8.0.
1 parent 583a24e commit dd447a2

File tree

2 files changed

+50
-21
lines changed

2 files changed

+50
-21
lines changed

.github/workflows/ci.yml

+50
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: Continuous integration
2+
3+
on: [push]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
strategy:
9+
fail-fast: true
10+
matrix:
11+
php: [7.3, 7.4, 8.0]
12+
stability: [prefer-lowest, prefer-stable]
13+
14+
name: PHP ${{ matrix.php }} - ${{ matrix.stability }}
15+
16+
steps:
17+
- name: Checkout code
18+
uses: actions/checkout@v2
19+
with:
20+
fetch-depth: 0
21+
22+
- name: Setup PHP
23+
uses: shivammathur/setup-php@v2
24+
with:
25+
php-version: ${{ matrix.php }}
26+
tools: composer:v2
27+
coverage: xdebug
28+
29+
- name: Install dependencies
30+
uses: nick-invision/retry@v1
31+
with:
32+
timeout_minutes: 5
33+
max_attempts: 5
34+
command: |
35+
composer update --${{ matrix.stability }} --prefer-dist --no-interaction --no-progress
36+
# revert updated composer.lock
37+
git checkout composer.lock
38+
39+
- name: Run tests
40+
run: php vendor/bin/phpunit
41+
42+
- name: Update scrutinizer-ci
43+
run: |
44+
wget https://scrutinizer-ci.com/ocular.phar
45+
php ocular.phar code-coverage:upload --format=php-clover log/coverage.xml
46+
47+
- name: Evaluate semantic versioning
48+
run: |
49+
wget http://psvcg.coreteks.org/php-semver-checker-git.phar
50+
php php-semver-checker-git.phar suggest -vvv

.travis.yml

-21
This file was deleted.

0 commit comments

Comments
 (0)