Skip to content

Commit

Permalink
add Psalms coverage (#3)
Browse files Browse the repository at this point in the history
* add coverage support

* standardize coverage output

* install `psalm-plugin-typecov` in workflow

* use relative directory

* Revert "use relative directory"

This reverts commit 18c09f7.

---------

Co-authored-by: tyler36 <[email protected]>
  • Loading branch information
tyler36 and tyler36 authored Feb 14, 2025
1 parent bb6f926 commit 9bbbed0
Show file tree
Hide file tree
Showing 5 changed files with 59 additions and 8 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/psalm.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ jobs:
with:
persist-credentials: false

- name: '🧹 Run Psalm'
uses: docker://ghcr.io/psalm/psalm-github-actions:latest
# with:
# security_analysis: true
- name: "🧹 Run Psalm"
uses: docker://ghcr.io/psalm/psalm-github-actions
with:
composer_require_dev: true
composer_ignore_platform_reqs: true
# security_analysis: true
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"lint:php:fix": "vendor/bin/psalter --issues=all"
},
"require-dev": {
"vimeo/psalm": "^6.2"
"vimeo/psalm": "^6.2",
"bafs/psalm-plugin-typecov": "dev-main"
}
}
49 changes: 46 additions & 3 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file added logs/psalms-coverage/.gitkeep
Empty file.
5 changes: 5 additions & 0 deletions psalm.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,9 @@
<directory name="vendor" />
</ignoreFiles>
</projectFiles>
<plugins>
<pluginClass class="BafS\PsalmTypecov\TypeCoverage">
<htmlReport output="logs/psalms-coverage/index.html" />
</pluginClass>
</plugins>
</psalm>

0 comments on commit 9bbbed0

Please sign in to comment.