weixin_39746229
2021-01-03 03:56 阅读 1

Add option to specify multiple threshold values for each threshold types

  • For single threshold value behavior will be same as present, i.e same threshold values is used to check against specified threshold types. Otherwise parse the value in the same order as the threshold type.

Usage (1). /p:Threshold=\"80,100,70\" /p:ThresholdType=\"line,branch,method\" (2). /p:Threshold=90 /p:ThresholdType=\"line,branch,method\" (3). /p:Threshold=\"80,90\" /p:ThresholdType=\"branch,method\"

closes https://github.com/coverlet-coverage/coverlet/issues/379

该提问来源于开源项目:coverlet-coverage/coverlet

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享

17条回答 默认 最新

  • weixin_39746229 weixin_39746229 2021-01-03 03:56

    https://github.com/tonerdo/coverlet/issues/379

    点赞 评论 复制链接分享
  • weixin_39945679 weixin_39945679 2021-01-03 03:56

    Codecov Report

    Merging #385 into master will increase coverage by 4.36%. The diff coverage is 100%.

    diff
    @@            Coverage Diff            @@
    ##           master    #385      +/-   ##
    =========================================
    + Coverage   87.13%   91.5%   +4.36%     
    =========================================
      Files          16      16              
      Lines        2106    2106              
    =========================================
    + Hits         1835    1927      +92     
    + Misses        271     179      -92
    
    点赞 评论 复制链接分享
  • weixin_39945679 weixin_39945679 2021-01-03 03:56

    Codecov Report

    Merging #385 into master will not change coverage. The diff coverage is n/a.

    diff
    @@           Coverage Diff           @@
    ##           master     #385   +/-   ##
    =======================================
      Coverage   91.96%   91.96%           
    =======================================
      Files          16       16           
      Lines        2229     2229           
    =======================================
      Hits         2050     2050           
      Misses        179      179
    
    点赞 评论 复制链接分享
  • weixin_39680154 weixin_39680154 2021-01-03 03:56

    what happens if I specify: (1). /p:Threshold="80,100,70" /p:ThresholdType="line,branch" (2). /p:Threshold="80,90" /p:ThresholdType="line,branch,method"

    点赞 评论 复制链接分享
  • weixin_39746229 weixin_39746229 2021-01-03 03:56

    It will throw a build error like

    (1) error : Threshold type flag count (2) and values count (3) doesnt match

    (2) error : Threshold type flag count (3) and values count (2) doesnt match

    点赞 评论 复制链接分享
  • weixin_39680154 weixin_39680154 2021-01-03 03:56

    I'm concerned that this addition adds some flexibility at the expense of increasing complexity of usage of this relatively simple option

    点赞 评论 复制链接分享
  • weixin_39746229 weixin_39746229 2021-01-03 03:56

    For our crossplatform .net project we would need this requirement (other windows C++ project we use similar threshold metric). The only other option would be to use the lowest threshold value for all coverage metric. This doesnt affect the existing behavior though when user passes the single threshold value.

    点赞 评论 复制链接分享
  • weixin_39635459 weixin_39635459 2021-01-03 03:56

    other windows C++ project we use similar threshold metric

    -subramanian-1 can you provide names of other coverage frameworks with this metrics checks support?

    点赞 评论 复制链接分享
  • weixin_39635459 weixin_39635459 2021-01-03 03:56

    /azp run

    点赞 评论 复制链接分享
  • weixin_39978444 weixin_39978444 2021-01-03 03:56

    Azure Pipelines successfully started running 1 pipeline(s).

    点赞 评论 复制链接分享
  • weixin_39635459 weixin_39635459 2021-01-03 03:56

    what do you think about this PR? Should we close and wait for more users request?

    点赞 评论 复制链接分享
  • weixin_39680154 weixin_39680154 2021-01-03 03:56

    I go with the second one. Let's put it on hold till we have more requests

    点赞 评论 复制链接分享
  • weixin_39635459 weixin_39635459 2021-01-03 03:56

    thank's -subramanian-1 for the effort here...we'll re-open/merge in future if we'll have more feature requests!

    点赞 评论 复制链接分享
  • weixin_40006965 weixin_40006965 2021-01-03 03:56

    I like this feature - could you please re-open and merge the PR?

    点赞 评论 复制链接分享
  • weixin_39635459 weixin_39635459 2021-01-03 03:56

    this PR needs some updated and also we should update the documentation accordingly.

    点赞 评论 复制链接分享
  • weixin_39858124 weixin_39858124 2021-01-03 03:56

    Hey all,

    This feature would be useful to me as well. Would be great if this feature could be added. Thanks!

    点赞 评论 复制链接分享
  • weixin_39635459 weixin_39635459 2021-01-03 03:56

    -subramanian-1 I see some interest for this feature, would you like to rebase and move to the end? If the default behavior is the the same I think we can merge. Also you should update the guide.

    Ah not obligate at all!If you're busy let me know I'll clone your branch and implement the missing part.

    点赞 评论 复制链接分享

相关推荐