Project

General

Profile

Actions

Bug #19279

closed

Allow `Coverage.supported?` to recognize oneshot lines mode

Added by kevin-j-m (Kevin Murphy) over 1 year ago. Updated over 1 year ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
ruby 3.2.0 (2022-12-25 revision a528908271) [x86_64-darwin22]
[ruby-core:111485]

Description

Currently in Ruby 3.2.0, Coverage's new supported? method (introduced in https://bugs.ruby-lang.org/issues/19026) does not recognize support for oneshot lines. Given that it is an available mode of coverage, I'm proposing that Coverage.supported? report that oneshot lines is supported.

Current behavior:

~|⇒ ruby -v
ruby 3.2.0 (2022-12-25 revision a528908271) [x86_64-darwin22]
~|⇒ irb
irb(main):001:0> require "coverage"
=> true
irb(main):002:0> Coverage.supported?(:lines)
=> true
irb(main):003:0> Coverage.supported?(:oneshot_lines)
=> false
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like1Like0Like0