Skip to content

Commit fc9d6e9

Browse files
committed
Add workflow.
Signed-off-by: Mior Muhammad Zaki <crynobone@gmail.com>
1 parent d758516 commit fc9d6e9

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed

.github/workflows/tests.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: tests
2+
3+
on:
4+
push:
5+
pull_request:
6+
schedule:
7+
- cron: '0 0 * * *'
8+
9+
jobs:
10+
test:
11+
runs-on: ${{ matrix.os }}
12+
strategy:
13+
fail-fast: false
14+
matrix:
15+
php: [7.4, 7.3]
16+
os: [ubuntu-latest, windows-latest]
17+
18+
name: PHP${{ matrix.php }} on ${{ matrix.os }}
19+
20+
steps:
21+
- name: Checkout code
22+
uses: actions/checkout@v1
23+
24+
- name: Cache dependencies
25+
uses: actions/cache@v1
26+
with:
27+
path: ~/.composer/cache/files
28+
key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}
29+
30+
- name: Setup PHP
31+
uses: shivammathur/setup-php@v2
32+
with:
33+
php-version: ${{ matrix.php }}
34+
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite3, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick
35+
coverage: none
36+
37+
- name: Install dependencies
38+
run: |
39+
composer update --prefer-stable --prefer-dist --no-interaction --no-suggest
40+
- name: Execute tests
41+
run: vendor/bin/phpunit

0 commit comments

Comments
 (0)