Skip to content

Commit 6ed3406

Browse files
authored
Run tests on Github CI and remove Travis CI (#201)
* Run tests on Github CI and remove Travis CI * allow newer PHPUnit
1 parent 93b9a10 commit 6ed3406

File tree

4 files changed

+39
-39
lines changed

4 files changed

+39
-39
lines changed

.github/workflows/ci.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: MO4 Coding Standard CI
2+
on:
3+
pull_request:
4+
push:
5+
jobs:
6+
run-tests:
7+
strategy:
8+
matrix:
9+
php_version:
10+
- 5.6
11+
- 7.0
12+
- 7.1
13+
- 7.2
14+
- 7.3
15+
- 7.4
16+
- 8.0
17+
- 8.1
18+
- 8.2
19+
- 8.3
20+
runs-on: ubuntu-latest
21+
steps:
22+
- name: Check out repository code
23+
uses: actions/checkout@v4
24+
- name: Install PHP
25+
uses: shivammathur/setup-php@v2
26+
with:
27+
php-version: ${{ matrix.php_version }}
28+
- name: Cache dependencies
29+
uses: actions/cache@v4
30+
with:
31+
path: '~/.cache/composer'
32+
key: "cache-composer-${{ hashFiles('composer.json') }}"
33+
restore-keys: 'cache-composer-'
34+
- name: Run composer
35+
run: composer update --prefer-dist --no-interaction --no-progress
36+
- name: Run tests
37+
run: ant test -Dcomposer.path=composer

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
cache.properties
22
phpunit.xml
3+
.phpunit.result.cache
34
composer.lock
45
composer.phar
56
vendor/

.travis.yml

Lines changed: 0 additions & 38 deletions
This file was deleted.

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"squizlabs/php_codesniffer": "^3.3.1"
2929
},
3030
"require-dev": {
31-
"phpunit/phpunit": "^5.0 || ^6.0 || ^7.0"
31+
"phpunit/phpunit": "^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.3.4"
3232
},
3333
"conflict": {
3434
"squizlabs/php_codesniffer": "<3 || >=4"

0 commit comments

Comments
 (0)