CoveredSourceCoveredBase

class Base

The base coverage output interface.

Definitions

def start

Start tracking coverage.

Implementation

def start
end

def clear

Discard any coverage data and restart tracking.

Implementation

def clear
end

def finish

Stop tracking coverage.

Implementation

def finish
end

def accept?(path)

Whether the given path should be accepted.

Signature

parameter path String

The source path.

returns Boolean

Whether the path should be included.

Implementation

def accept?(path)
	true
end

def mark(path, lineno, value)

Mark coverage for the given path and line number.

Signature

parameter path String

The source path.

parameter lineno Integer

The starting line number.

parameter value Integer | Array(Integer)

The execution count or counts to add.

Implementation

def mark(path, lineno, value)
end

def add(coverage)

Add a coverage object.

Signature

parameter coverage Covered::Coverage

The coverage object to add.

Implementation

def add(coverage)
end

def each

Enumerate the coverage data.

Signature

yields {|coverage| ...}
parameter coverage Coverage

The coverage data, including the source file and execution counts.

Implementation

def each
end

def relative_path(path)

Convert a path to a relative path.

Signature

parameter path String

The source path.

returns String

The relative path.

Implementation

def relative_path(path)
	path
end

def expand_path(path)

Expand a path relative to this output.

Signature

parameter path String

The path to expand.

returns String

The expanded path.

Implementation

def expand_path(path)
	path
end