Class: Xccov

Inherits:
Object
  • Object
show all
Defined in:
lib/xccov-parse.rb,
lib/xccov-parse/parse.rb,
lib/xccov-parse/version.rb

Defined Under Namespace

Classes: Parse

Constant Summary collapse

VERSION =
"0.2.0"

Instance Method Summary collapse

Constructor Details

#initializeXccov

Returns a new instance of Xccov.

Examples:


xccov = Xccov.new
xccov.help
json = xccov.view '--only-targets', '--json', '/path/to/Build/Logs/Test/*.xccovreport'
parsed = Xccov::Parse.new(json: json)
parsed.targets_line_coverage["test.examples.app"] #=> 0.35


14
15
16
# File 'lib/xccov-parse.rb', line 14

def initialize
  @xccov = "#{get_xcrun} xccov"
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method, *args, &_block) ⇒ Object (private)



31
32
33
34
35
36
37
# File 'lib/xccov-parse.rb', line 31

def method_missing(method, *args, &_block)
  if respond_to_missing?
    run(@xccov, method, args)
  else
    super
  end
end