Use codecov action
Signed-off-by: Raimund Schlüßler <raimund.schluessler@mailbox.org>
This commit is contained in:
parent
60d21d1c3b
commit
1169542a6d
|
@ -27,11 +27,14 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: npm ci
|
run: npm ci
|
||||||
|
|
||||||
- name: Set up Codecov
|
|
||||||
run: npm install -g codecov
|
|
||||||
- name: Test
|
- name: Test
|
||||||
run: npm run test
|
run: npm run test
|
||||||
env:
|
env:
|
||||||
CI: true
|
CI: true
|
||||||
- name: Upload coverage
|
|
||||||
run: bash <(curl -s https://codecov.io/bash) -cF javascript -t ${{ secrets.CODECOV_TOKEN }};
|
- name: Upload coverage to Codecov
|
||||||
|
uses: codecov/codecov-action@v1
|
||||||
|
with:
|
||||||
|
file: ./coverage/coverage-final.json
|
||||||
|
flags: javascript
|
||||||
|
fail_ci_if_error: true
|
||||||
|
|
|
@ -78,9 +78,16 @@ jobs:
|
||||||
- name: PHPUnit unit & integration
|
- name: PHPUnit unit & integration
|
||||||
working-directory: apps/${{ env.APP_NAME }}
|
working-directory: apps/${{ env.APP_NAME }}
|
||||||
run: |
|
run: |
|
||||||
./vendor/phpunit/phpunit/phpunit -c phpunit.xml --coverage-clover=coverage-unit.xml
|
./vendor/phpunit/phpunit/phpunit -c phpunit.xml
|
||||||
./vendor/phpunit/phpunit/phpunit -c phpunit.integration.xml --coverage-clover=coverage-integration.xml
|
./vendor/phpunit/phpunit/phpunit -c phpunit.integration.xml
|
||||||
bash <(curl -s https://codecov.io/bash) -cF php -t ${{ secrets.CODECOV_TOKEN }};
|
|
||||||
|
- name: Upload coverage to Codecov
|
||||||
|
if: ${{ matrix.server-versions == 'master' }}
|
||||||
|
uses: codecov/codecov-action@v1
|
||||||
|
with:
|
||||||
|
file: apps/${{ env.APP_NAME }}/clover.unit.xml
|
||||||
|
flags: php
|
||||||
|
fail_ci_if_error: true
|
||||||
|
|
||||||
mysql:
|
mysql:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
|
@ -220,6 +220,8 @@ pip-log.txt
|
||||||
# Unit test / coverage reports
|
# Unit test / coverage reports
|
||||||
.coverage
|
.coverage
|
||||||
.tox
|
.tox
|
||||||
|
clover.unit.xml
|
||||||
|
clover.integration.xml
|
||||||
|
|
||||||
#Translations
|
#Translations
|
||||||
*.mo
|
*.mo
|
||||||
|
|
4
Makefile
4
Makefile
|
@ -176,8 +176,8 @@ test-php:
|
||||||
phpunit -c phpunit.integration.xml
|
phpunit -c phpunit.integration.xml
|
||||||
|
|
||||||
test-php-coverage:
|
test-php-coverage:
|
||||||
phpunit -c phpunit.xml --coverage-clover=coverage-unit.xml
|
phpunit -c phpunit.xml
|
||||||
phpunit -c phpunit.integration.xml --coverage-clover=coverage-integration.xml
|
phpunit -c phpunit.integration.xml
|
||||||
|
|
||||||
lint-php:
|
lint-php:
|
||||||
php composer.phar run-script cs:check
|
php composer.phar run-script cs:check
|
||||||
|
|
|
@ -19,4 +19,8 @@
|
||||||
</exclude>
|
</exclude>
|
||||||
</whitelist>
|
</whitelist>
|
||||||
</filter>
|
</filter>
|
||||||
|
<logging>
|
||||||
|
<!-- and this is where your report will be written -->
|
||||||
|
<log type="coverage-clover" target="./clover.integration.xml"/>
|
||||||
|
</logging>
|
||||||
</phpunit>
|
</phpunit>
|
||||||
|
|
|
@ -19,4 +19,8 @@
|
||||||
</exclude>
|
</exclude>
|
||||||
</whitelist>
|
</whitelist>
|
||||||
</filter>
|
</filter>
|
||||||
|
<logging>
|
||||||
|
<!-- and this is where your report will be written -->
|
||||||
|
<log type="coverage-clover" target="./clover.unit.xml"/>
|
||||||
|
</logging>
|
||||||
</phpunit>
|
</phpunit>
|
||||||
|
|
Loading…
Reference in New Issue