Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add coverage and coveralls integration #5

Merged
merged 5 commits into from Jan 24, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions .coveralls.yml
@@ -0,0 +1,2 @@
coverage_clover: data/tmp/coverage.xml
json_path: data/tmp/coveralls-upload.json
7 changes: 7 additions & 0 deletions .github/workflows/test.yml
Expand Up @@ -45,3 +45,10 @@ jobs:

- name: Run tests
run: composer test

- name: Coveralls
if: matrix.php-version == 7.4
env:
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
php vendor/bin/php-coveralls -v
1 change: 1 addition & 0 deletions README.md
@@ -1,3 +1,4 @@
# commit-message-creator

[![Test](https://github.com/violinist-dev/commit-message-creator/actions/workflows/test.yml/badge.svg)](https://github.com/violinist-dev/commit-message-creator/actions/workflows/test.yml)
[![Coverage Status](https://coveralls.io/repos/github/violinist-dev/commit-message-creator/badge.svg?branch=main)](https://coveralls.io/github/violinist-dev/commit-message-creator?branch=main)
2 changes: 1 addition & 1 deletion composer.json
Expand Up @@ -32,7 +32,7 @@
"require-dev": {
"phpunit/phpunit": "^6.5",
"squizlabs/php_codesniffer": "^3.4",
"satooshi/php-coveralls": "^2.0",
"php-coveralls/php-coveralls": "^2.0",
"violinist-dev/violinist-config": "dev-master"
},
"require": {
Expand Down
10 changes: 10 additions & 0 deletions phpunit.xml.dist
Expand Up @@ -14,4 +14,14 @@
<directory>tests</directory>
</testsuite>
</testsuites>
<logging>
<log type="coverage-html" target="data/tmp/coverage"
lowUpperBound="35" highLowerBound="70" />
<log type="coverage-clover" target="data/tmp/coverage.xml" />
</logging>
<filter>
<whitelist>
<directory>src</directory>
</whitelist>
</filter>
</phpunit>