3333
3434 - name : Get Composer Cache Directory
3535 id : composer-cache
36- run : echo "::set-output name= dir:: $(composer config cache-files-dir)"
36+ run : echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
3737
3838 - name : Cache dependencies
3939 uses : actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
4848 - name : Run phpcpd tests
4949 run : vendor/bin/phpcpd src --exclude=src/Entity --exclude=src/Repository
5050
51- phpunit :
52- name : PHPUnit
51+ tests :
52+ name : Tests
5353 runs-on : ubuntu-latest
5454 steps :
5555 - name : Checkout
6464
6565 - name : Get Composer Cache Directory
6666 id : composer-cache
67- run : echo "::set-output name= dir:: $(composer config cache-files-dir)"
67+ run : echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
6868
6969 - name : Cache dependencies
7070 uses : actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
@@ -77,19 +77,38 @@ jobs:
7777 run : composer install --prefer-dist --no-progress --no-suggest --no-interaction --no-scripts
7878
7979 - name : Run phpunit tests
80- run : bin/phpunit --coverage-text --coverage-xml=build/logs/phpunit/coverage-xml --coverage-clover=build/logs/phpunit/clover.xml --log-junit=build/logs/phpunit/unit .xml --colors=never --order-by=random --exclude-group=integration
80+ run : bin/phpunit --coverage-text --coverage-xml=build/logs/phpunit/coverage-xml --coverage-clover=build/logs/phpunit/clover.xml --log-junit=build/logs/phpunit/junit .xml --colors=never --order-by=random --exclude-group=integration
8181
82- # - name: Run Infection tests
83- # run: vendor/bin/infection --coverage=build/logs/phpunit --min-covered-msi=85 --threads=30
82+ - name : Run Infection tests
83+ run : vendor/bin/infection --skip-initial-tests -- coverage=build/logs/phpunit --min-covered-msi=80 --threads=30
8484
85- # - name: Run Integration tests
86- # run: bin/phpunit --log-junit=build/logs/phpunit/integration.xml --colors=never --order-by=random --group=integration
85+ - name : Install MariaDB
86+ uses : getong/mariadb-action@v1.11
87+ with :
88+ mysql database : ' bewelcome_test'
89+ mysql user : ' bewelcome'
90+ mysql password : ' bewelcome'
8791
88- # - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # tag=v4.6.2
89- # if: ${{ always() }}
90- # with:
91- # name: infection.log
92- # path: infection.log
92+ - name : Create test database
93+ run : bin/console test:database:create --env=test
94+
95+ - name : Setup Yarn
96+ uses : threeal/setup-yarn-action@v2.0.0
97+ with :
98+ version : latest
99+ cache : false
100+
101+ - name : Install yarn dependencies and run webpack
102+ run : yarn install --frozen-lock ; yarn encore dev
103+
104+ - name : Run Integration tests
105+ run : bin/phpunit --log-junit=build/logs/phpunit/integration.xml --colors=never --order-by=random --group=integration
106+
107+ - uses : actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # tag=v4.6.2
108+ if : ${{ always() }}
109+ with :
110+ name : infection.log
111+ path : infection.log
93112
94113 phploc :
95114 name : PHPLoc
@@ -106,7 +125,7 @@ jobs:
106125
107126 - name : Get Composer Cache Directory
108127 id : composer-cache
109- run : echo "::set-output name= dir:: $(composer config cache-files-dir)"
128+ run : echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
110129
111130 - name : Cache dependencies
112131 uses : actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
@@ -137,7 +156,7 @@ jobs:
137156
138157 - name : Get Composer Cache Directory
139158 id : composer-cache
140- run : echo "::set-output name= dir:: $(composer config cache-files-dir)"
159+ run : echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
141160
142161 - name : Cache dependencies
143162 uses : actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
@@ -168,7 +187,7 @@ jobs:
168187#
169188# - name: Get Composer Cache Directory
170189# id: composer-cache
171- # run: echo "::set-output name= dir:: $(composer config cache-files-dir)"
190+ # run: echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
172191#
173192# - name: Cache dependencies
174193# uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
@@ -198,7 +217,7 @@ jobs:
198217
199218 - name : Get Composer Cache Directory
200219 id : composer-cache
201- run : echo "::set-output name= dir:: $(composer config cache-files-dir)"
220+ run : echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
202221
203222 - name : Cache dependencies
204223 uses : actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
@@ -228,7 +247,7 @@ jobs:
228247
229248 - name : Get Composer Cache Directory
230249 id : composer-cache
231- run : echo "::set-output name= dir:: $(composer config cache-files-dir)"
250+ run : echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
232251
233252 - name : Cache dependencies
234253 uses : actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
@@ -258,7 +277,7 @@ jobs:
258277
259278 - name : Get Composer Cache Directory
260279 id : composer-cache
261- run : echo "::set-output name= dir:: $(composer config cache-files-dir)"
280+ run : echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
262281
263282 - name : Cache dependencies
264283 uses : actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
@@ -288,7 +307,7 @@ jobs:
288307
289308 - name : Get Composer Cache Directory
290309 id : composer-cache
291- run : echo "::set-output name= dir:: $(composer config cache-files-dir)"
310+ run : echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
292311
293312 - name : Cache dependencies
294313 uses : actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
@@ -322,7 +341,7 @@ jobs:
322341
323342 - name : Get Composer Cache Directory
324343 id : composer-cache
325- run : echo "::set-output name= dir:: $(composer config cache-files-dir)"
344+ run : echo "dir= $(composer config cache-files-dir)" >> $GITHUB_OUTPUT
326345
327346 - name : Cache dependencies
328347 uses : actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # tag=v4.2.4
@@ -341,3 +360,14 @@ jobs:
341360
342361 - name : Run JS security checker
343362 run : yarn audit --groups dependencies
363+
364+
365+
366+
367+
368+
369+
370+
371+
372+
373+
0 commit comments