【问题标题】:How can I make C8 output total code coverage %?如何使 C8 输出总代码覆盖率 %?
【发布时间】:2020-10-26 16:07:04
【问题描述】:

我能够使用 c8 生成代码覆盖率报告。

但是我如何每次输出总覆盖率%?目前,只有当它小于这样的阈值时,它才会输出总覆盖率%。

但我想在每次运行时查看 %。

配置:

{
  "include": "app",
  "check-coverage": true,
  "lines": 99,
  "reporter": ["text","cobertura"]
}

【问题讨论】:

    标签: node.js mocha.js code-coverage chai nyc


    【解决方案1】:

    我只需要添加“文本摘要”作为记者之一。

    "reporter": ["text","text-summary","cobertura"]
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2023-03-28
      • 2023-02-04
      • 2013-03-08
      • 2011-01-14
      • 1970-01-01
      • 2012-06-30
      • 1970-01-01
      相关资源
      最近更新 更多