-
Notifications
You must be signed in to change notification settings - Fork 0
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
GitHub 上でカバレッジを確認できるようにする #72
base: main
Are you sure you want to change the base?
Conversation
@@ -1,5 +1,7 @@ | |||
# lerna-app-library | |||
|
|||
[![Coverage Status](https://coveralls.io/repos/github/lerna-stack/lerna-app-library/badge.svg?branch=main)](https://coveralls.io/github/lerna-stack/lerna-app-library?branch=main) | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
結果を見る限り、命令網羅(C0)しか取得できていないように見える。
https://coveralls.io/github/lerna-stack/lerna-app-library
設定で、branch coverage の機能は有効化されている。
https://coveralls.io/github/lerna-stack/lerna-app-library/settings
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coveralls の API ドキュメントを確認すると、coverage
という(行ごとのカバレッジを表現する?)フィールドの他に branches
という(分岐のカバレッジを表現する?)フィールドがある模様。coverage
は必須のフィールドだが、branches
はオプショナルなフィールドとして定義されている。
OBJECTS: SOURCE FILE
しかし、sbt-coveralls の実装を確認すると coverage
フィールドしか設定されていないように見える。
gen.writeFieldName("coverage") gen.writeStartArray() report.lineCoverage.foreach { case Some(x) => gen.writeNumber(x) case _ => gen.writeNull() }sbt-coveralls/CoverallPayloadWriter.scala at v1.3.1 · scoverage/sbt-coveralls
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
別のプロジェクトだが、分岐網羅のステータスが確認できているプロジェクトがあった。
sbt-coveralls が brances
をサポートすると、lerna-app-library においても同様の表示ができるようになることが期待できる。
https://coveralls.io/ というサービスを使う