File tree Expand file tree Collapse file tree 1 file changed +80
-0
lines changed Expand file tree Collapse file tree 1 file changed +80
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : CI
2
+
3
+ on : [push]
4
+
5
+ jobs :
6
+ phpstan :
7
+ runs-on : ubuntu-latest
8
+
9
+ steps :
10
+ - uses : actions/checkout@v3
11
+
12
+ - name : Cache Composer dependencies
13
+ uses : actions/cache@v3
14
+ with :
15
+ path : /tmp/composer-cache
16
+ key : ${{ runner.os }}-${{ hashFiles('**/composer.lock') }}
17
+
18
+ - uses : php-actions/composer@v6
19
+ with :
20
+ php_version : 8.2
21
+
22
+ - uses : php-actions/phpstan@v3
23
+ with :
24
+ php_version : 8.2
25
+ path : src/
26
+ version : composer
27
+ configuration : phpstan.neon
28
+ command : analyse
29
+
30
+ phpunit :
31
+ runs-on : ubuntu-latest
32
+
33
+ services :
34
+ mysql :
35
+ image : mariadb:10.11
36
+ env :
37
+ MARIADB_DATABASE : kbpdb
38
+ MARIADB_USER : kbpdb
39
+ MARIADB_PASSWORD : password
40
+ options : >-
41
+ --health-cmd "mysqladmin ping"
42
+ --health-interval 10s
43
+ --health-timeout 5s
44
+ --health-retries 5
45
+ ports :
46
+ - 3306:3306
47
+
48
+ postgres :
49
+ image : postgres:15
50
+ env :
51
+ POSTGRES_PASSWORD : password
52
+ options : >-
53
+ --health-cmd "pg_isready"
54
+ --health-interval 10s
55
+ --health-timeout 5s
56
+ --health-retries 5
57
+ ports :
58
+ - 5432:5432
59
+
60
+ steps :
61
+ - uses : actions/checkout@v3
62
+
63
+ - name : Cache Composer dependencies
64
+ uses : actions/cache@v3
65
+ with :
66
+ path : /tmp/composer-cache
67
+ key : ${{ runner.os }}-${{ hashFiles('**/composer.lock') }}
68
+
69
+ - uses : php-actions/composer@v6
70
+ with :
71
+ php_version : 8.2
72
+
73
+ - uses : php-actions/phpunit@v4
74
+ with :
75
+ php_version : 8.2
76
+ php_extensions : " pcntl intl pdo_mysql pdo_pgsql"
77
+ version : composer
78
+ configuration : phpunit.xml
79
+ args : ' --testdox'
80
+
You can’t perform that action at this time.
0 commit comments