1
- # yaml-language-server: $schema=https://json.schemastore.org/github-workflow
2
-
3
1
name : " Integrate"
4
2
5
3
on :
@@ -31,18 +29,34 @@ jobs:
31
29
- name : " Set up PHP"
32
30
uses : " shivammathur/setup-php@v2"
33
31
with :
34
- php-version : " 8.1"
32
+ php-version : " 8.3"
33
+ extensions : " json, mbstring, openssl, sqlite3, curl, uuid"
34
+ tools : castor
35
35
36
36
- name : " Checkout code"
37
37
uses : " actions/checkout@v4"
38
38
39
+ - name : " Fetch Git base reference"
40
+ run : " git fetch --depth=1 origin ${GITHUB_BASE_REF}"
41
+
42
+ - name : " Validate Composer configuration"
43
+ run : " castor validate"
44
+
39
45
- name : " Install dependencies"
40
46
uses : " ramsey/composer-install@v3"
41
47
with :
42
- dependency-versions : " highest"
48
+ dependency-versions : " ${{ matrix.dependencies }}"
49
+ composer-options : " --optimize-autoloader"
50
+
51
+ - name : " Cache dependencies"
52
+ uses : " actions/cache@v4"
53
+ id : " cache"
54
+ with :
55
+ path : " composer-cache"
56
+ key : " ${{ runner.os }}-${{ hashFiles('**/composer.json') }}"
43
57
44
58
- name : " Check source code for syntax errors"
45
- run : " composer exec -- parallel- lint src/ tests/ "
59
+ run : " castor lint"
46
60
47
61
unit_tests :
48
62
name : " 2️⃣ Unit and functional tests"
54
68
operating-system :
55
69
- " ubuntu-latest"
56
70
php-version :
57
- - " 8.1"
58
- - " 8.2"
59
71
- " 8.3"
60
72
dependencies :
61
73
- " lowest"
67
79
with :
68
80
php-version : " ${{ matrix.php-version }}"
69
81
extensions : " json, mbstring, openssl, sqlite3, curl, uuid"
82
+ tools : castor
70
83
coverage : " xdebug"
71
84
72
85
- name : " Checkout code"
79
92
composer-options : " --optimize-autoloader"
80
93
81
94
- name : " Execute unit tests"
82
- run : " make ci-cc"
83
-
84
- # - name: Send coverage to Coveralls
85
- # if: "matrix.php-version == '8.1' && matrix.dependencies == 'highest'"
86
- # env:
87
- # COVERALLS_REPO_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
88
- # run: |
89
- # wget "https://github.com/php-coveralls/php-coveralls/releases/download/v2.5.2/php-coveralls.phar"
90
- # php ./php-coveralls.phar -v
95
+ run : " castor test --coverage-text"
91
96
92
97
static_analysis :
93
98
name : " 3️⃣ Static Analysis"
@@ -99,23 +104,21 @@ jobs:
99
104
- name : " Set up PHP"
100
105
uses : " shivammathur/setup-php@v2"
101
106
with :
102
- php-version : " 8.1 "
107
+ php-version : " 8.3 "
103
108
extensions : " json, mbstring, openssl, sqlite3, curl, uuid"
109
+ tools : castor
104
110
105
111
- name : " Checkout code"
106
112
uses : " actions/checkout@v4"
107
113
108
- - name : " Validate Composer configuration"
109
- run : " composer validate --strict"
110
-
111
114
- name : " Install dependencies"
112
115
uses : " ramsey/composer-install@v3"
113
116
with :
114
117
dependency-versions : " highest"
115
118
composer-options : " --optimize-autoloader"
116
119
117
120
- name : " Execute static analysis"
118
- run : " make st "
121
+ run : " castor stan "
119
122
120
123
coding_standards :
121
124
name : " 4️⃣ Coding Standards"
@@ -127,23 +130,50 @@ jobs:
127
130
- name : " Set up PHP"
128
131
uses : " shivammathur/setup-php@v2"
129
132
with :
130
- php-version : " 8.1 "
133
+ php-version : " 8.3 "
131
134
extensions : " json, mbstring, openssl, sqlite3, curl, uuid"
135
+ tools : castor
132
136
133
137
- name : " Checkout code"
134
138
uses : " actions/checkout@v4"
135
139
140
+ - name : " Install dependencies"
141
+ uses : " ramsey/composer-install@v3"
142
+ with :
143
+ dependency-versions : " highest"
144
+ composer-options : " --optimize-autoloader"
145
+
136
146
- name : " Check adherence to EditorConfig"
137
147
uses : " greut/eclint-action@v0"
138
148
149
+ - name : " Check coding style"
150
+ run : " castor cs"
151
+
152
+ check_licenses :
153
+ name : " 5️⃣ Check licenses"
154
+ needs :
155
+ - " byte_level"
156
+ - " syntax_errors"
157
+ runs-on : " ubuntu-latest"
158
+ steps :
159
+ - name : " Set up PHP"
160
+ uses : " shivammathur/setup-php@v2"
161
+ with :
162
+ php-version : " 8.3"
163
+ extensions : " json, mbstring, openssl, sqlite3, curl, uuid"
164
+ tools : castor
165
+
166
+ - name : " Checkout code"
167
+ uses : " actions/checkout@v4"
168
+
139
169
- name : " Install dependencies"
140
170
uses : " ramsey/composer-install@v3"
141
171
with :
142
172
dependency-versions : " highest"
143
173
composer-options : " --optimize-autoloader"
144
174
145
175
- name : " Check coding style"
146
- run : " make ci-cs "
176
+ run : " castor check-licenses "
147
177
148
178
rector_checkstyle :
149
179
name : " 6️⃣ Rector Checkstyle"
@@ -155,24 +185,22 @@ jobs:
155
185
- name : " Set up PHP"
156
186
uses : " shivammathur/setup-php@v2"
157
187
with :
158
- php-version : " 8.1 "
188
+ php-version : " 8.3 "
159
189
extensions : " json, mbstring, openssl, sqlite3, curl, uuid"
190
+ tools : castor
160
191
coverage : " xdebug"
161
192
162
193
- name : " Checkout code"
163
194
uses : " actions/checkout@v4"
164
195
165
- - name : " Fetch Git base reference"
166
- run : " git fetch --depth=1 origin ${GITHUB_BASE_REF}"
167
-
168
196
- name : " Install dependencies"
169
197
uses : " ramsey/composer-install@v3"
170
198
with :
171
199
dependency-versions : " highest"
172
200
composer-options : " --optimize-autoloader"
173
201
174
202
- name : " Execute Rector"
175
- run : " make rector"
203
+ run : " castor rector"
176
204
177
205
exported_files :
178
206
name : " 7️⃣ Exported files"
0 commit comments