Class: SimpleCov::Formatter::WorkspaceLcovFormatter

Inherits:
Object
  • Object
show all
Defined in:
lib/simplecov-workspace-lcov.rb,
lib/simplecov-workspace-lcov/version.rb,
lib/simplecov-workspace-lcov/configuration.rb

Defined Under Namespace

Classes: Configuration

Constant Summary collapse

VERSION =
"0.1.0"

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.config {|@config| ... } ⇒ Object

Yields:



22
23
24
25
26
27
28
# File 'lib/simplecov-workspace-lcov.rb', line 22

def config
  @config ||= Configuration.new

  yield @config if block_given?

  @config
end

Instance Method Details

#format(result) ⇒ Object



9
10
11
12
13
14
15
16
17
18
19
# File 'lib/simplecov-workspace-lcov.rb', line 9

def format(result)
  create_output_directory!

  if report_with_single_file?
    write_lcov_to_single_file!(result.files)
  else
    result.files.each { |file| write_lcov!(file) }
  end

  puts "Lcov style coverage report generated for #{result.command_name} to #{lcov_results_path}"
end