File tree 2 files changed +59
-10
lines changed 2 files changed +59
-10
lines changed Original file line number Diff line number Diff line change
1
+ name : Code Style test
2
+ on :
3
+ push :
4
+ workflow_dispatch :
5
+ pull_request :
6
+
7
+ jobs :
8
+
9
+ codestyle :
10
+ runs-on : ubuntu-latest
11
+ strategy :
12
+ matrix :
13
+ php-versions :
14
+ - ' 8.3'
15
+
16
+ name : with PHP ${{ matrix.php-versions }}
17
+ steps :
18
+ - name : Checkout
19
+ uses : actions/checkout@v4
20
+
21
+ - name : Install PHP ${{ matrix.php-versions }}
22
+ uses : shivammathur/setup-php@v2
23
+ with :
24
+ php-version : ${{ matrix.php-versions }}
25
+ tools : composer
26
+
27
+ - name : Validate composer.json and composer.lock
28
+ run : composer validate --strict
29
+
30
+ - name : Get composer cache directory
31
+ id : composer-cache
32
+ run : echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
33
+
34
+ - name : Cache dependencies
35
+ uses : actions/cache@v4
36
+ with :
37
+ path : ${{ steps.composer-cache.outputs.dir }}
38
+ key : ${{ runner.os }}-composer-${{ matrix.php-versions }}-${{ hashFiles('**/composer.lock') }}
39
+ restore-keys : ${{ runner.os }}-composer-${{ matrix.php-versions }}-
40
+
41
+ - name : Install dependencies
42
+ run : composer install --no-interaction --prefer-dist
43
+
44
+ - name : Check codestyle
45
+ run : ./vendor/bin/phpcs --standard=PEAR src/
Original file line number Diff line number Diff line change 1
- name : JsonMapper tests
2
- on : [push, workflow_dispatch]
1
+ name : PHPUnit tests
2
+ on :
3
+ push :
4
+ workflow_dispatch :
5
+ pull_request :
6
+
3
7
jobs :
4
- test :
8
+
9
+ phpunit :
5
10
runs-on : ubuntu-latest
6
11
strategy :
7
12
matrix :
@@ -13,12 +18,14 @@ jobs:
13
18
- ' 8.0'
14
19
- ' 8.1'
15
20
- ' 8.2'
16
- name : PHP ${{ matrix.php-versions }}
21
+ - ' 8.3'
22
+
23
+ name : using PHP ${{ matrix.php-versions }}
17
24
steps :
18
25
- name : Checkout
19
- uses : actions/checkout@v3
26
+ uses : actions/checkout@v4
20
27
21
- - name : Install PHP
28
+ - name : Install PHP ${{ matrix.php-versions }}
22
29
uses : shivammathur/setup-php@v2
23
30
with :
24
31
php-version : ${{ matrix.php-versions }}
30
37
run : echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
31
38
32
39
- name : Cache dependencies
33
- uses : actions/cache@v3
40
+ uses : actions/cache@v4
34
41
with :
35
42
path : ${{ steps.composer-cache.outputs.dir }}
36
43
key : ${{ runner.os }}-composer-${{ matrix.php-versions }}-${{ hashFiles('**/composer.lock') }}
41
48
42
49
- name : Run unit tests
43
50
run : XDEBUG_MODE=coverage ./vendor/bin/phpunit --coverage-text
44
-
45
- - name : Check codestyle
46
- run : ./vendor/bin/phpcs --standard=PEAR src/
You can’t perform that action at this time.
0 commit comments