在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):killy971/hpc-coveralls开源软件地址(OpenSource Url):https://github.com/killy971/hpc-coveralls开源编程语言(OpenSource Language):Haskell 100.0%开源软件介绍(OpenSource Introduction):hpc-coverallshpc-coveralls converts and sends Haskell projects hpc code coverage to coverall.io. At the moment, only Travis CI has been tested, but hpc-coveralls should be compatible with other CI services (Check hpc-coveralls is still under development and any contributions are welcome! UsageTravis CIBelow is the simplest example of configuration for your project language: haskell
ghc: 7.8
script:
- cabal configure --enable-tests --enable-library-coverage && cabal build && cabal test
after_script:
- cabal install hpc-coveralls
- hpc-coveralls [options] [test-suite-names] When building with Cabal 1.22 or a newer version, use the If the build fails during the test phase with an error message starting by "hpc:", just replace the before_install:
- cabal install hpc-coveralls
script:
- cabal configure --enable-tests --enable-library-coverage && cabal build
- run-cabal-test [options] [cabal-test-options]
after_script:
- hpc-coveralls [options] [test-suite-names] This will prevent the build to fail because of hpc related reasons, which are usually not fatal and should not affect the coverage data. Details are available in the next section. You may also experience some issues related to your project dependencies, which can be solved by using the after_script:
- cabal sandbox init && cabal install hpc-coveralls
- .cabal-sandbox/bin/hpc-coveralls [options] [test-suite-names] For a real world example usage, please refer to this-project The run-cabal-test commandUnder certain conditions related to the project structure and the version of hpc, To prevent this from happening, hpc-coveralls provides the /^Test suite .*: FAIL$/ Below are some of the conditions under which you will likely need to use
OptionsThe run-cabal-test --cabal-name=cabal-1.20 The hpc-coveralls commandThis command parses the hpc generated output, converts its to Coveralls json format and finally sends it to coveralls.io over http. hpc-coveralls test1 test2 Options--exclude-dirThe hpc-coveralls --exclude-dir=test [test-suite-names] You can specify multiple excluded folders by using the following example syntax: hpc-coveralls --exclude-dir=test1 --exclude-dir=test2 [test-suite-names] --coverage-modeAs Coveralls doesn't support partial-line coverage yet, hpc-coveralls currently converts hpc coverage data into line based coverage data, which is the only format supported at the moment.
The
Note that
Please also note that there is an open issue on coveralls issue tracker in order to improve this (add support for partial line coverage). --repo-tokenThis option allows to specify your repo token when sending the report to coveralls.io. --display-reportThis boolean option prints the raw json coverage report to be sent to coveralls.io. --dont-sendThis boolean option prevents hpc-coveralls from sending the coverage report to coveralls.io.
This option can be used together with --curl-verboseThis boolean option enables curl verbose mode and prints the raw json response received after posting the coverage report to coveralls.io. --cabal-fileUse this option to specify the cabal file of the coverage report target package. This might be required in some cases, especially when building with cabal >= 1.22 and ghc >= 7.10, although hpc-coveralls assumes the package cabal file to be the unique file of extension ".cabal" in the current directory if it exists. For further details check this issue. --service-nameThis option allows you to override the --service-name=travis-pro LimitationsBecause of the way hpc works, coverage data is only generated for modules that are referenced directly or indirectly by the test suites. As a result, the total package coverage computed by coveralls may be higher than what it really is. An option will be added soon in order to allow specifying source folders to include in the total coverage computation. Contributinghpc-coveralls is still under development and any contributions are welcome! Please share your comments and suggestions on hpc-coveralls Gitter channel! LicenseBSD3 (tl;dr) Notes
|
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论