webdriverio/webdriverio

[💡 Feature]: allow in wdio-devtools-service coverageReporter multiple report types

Open

#8,050 opened on 2022年2月23日

GitHub で見る
 (9 comments) (0 reactions) (0 assignees)JavaScript (6,029 stars) (1,793 forks)batch import
EnhancementIdea 💡help wanted

説明

Is your feature request related to a problem?

Having multiple formats of coverage reports of the same test run is very common

  • HTML for test-writer
  • Text std as fast check for anyone
  • JSON for quality gates

NYC can do this with multiple ---reporter arguments see

But WDIO allows only one type and is not exposing the raw data, as NYC is doing it; in '.nyc_output'.

So there is no way to create another report.

Describe the solution you'd like.

// wdio.conf.js
services: [
    ['devtools', {
        coverageReporter: {
            enable: true,
            type: [ 'html', 'text' ],  // => be able to declare this
            logDir: __dirname + '/coverage'
        }
    }]
]

Describe alternatives you've considered.

Write the raw coverage results to .nyc_output. This would also enable to create multiple coverage reports.

Additional context

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct

コントリビューターガイド