ExIntegrationCoveralls (ExIntegrationCoveralls v0.9.0)

Run-time system code line-level coverage analysis.

Link to this section Summary

Functions

Get run-time env elxiir application total coverage.

Get an overall integration test coverage analysis report of an OTP application

Get an overall integration test coverage rate of an OTP application

Post run-time env elxiir application coverage to remote coverage service.

Enable run-time env elxiir application coverage collection.

Link to this section Functions

Link to this function

execute(compiled_beam_dir_path)

Link to this function

get_app_total_cov(app_name)

Get run-time env elxiir application total coverage.

parameters

Parameters

  • app_name: application name, It is a string.
Link to this function

get_coverage_report(compile_time_source_lib_abs_path \\ File.cwd!(), source_code_abs_path \\ File.cwd!())

Get an overall integration test coverage analysis report of an OTP application

parameters

Parameters

  • compile_time_source_lib_abs_path: source code project abs path in compile-time machine.
  • source_lib_absolute_path: source code project abs path in run-time machine.

examples

Examples

%{
  coverage: 50,
  files: [
    %Stats.Source{
      coverage: 50,
      filename: "test/fixtures/test.ex",
      hits: 1,
      misses: 1,
      sloc: 2,
      source: [
        %Stats.Line{coverage: 0, source: "defmodule Test do"},
        %Stats.Line{coverage: 1, source: "  def test do"},
        %Stats.Line{coverage: nil, source: "  end"},
        %Stats.Line{coverage: nil, source: "end"}
      ]
    }
  ],
  hits: 1,
  misses: 1,
  sloc: 2
}
Link to this function

get_total_coverage(compile_time_source_lib_abs_path \\ File.cwd!(), source_code_abs_path \\ File.cwd!())

Get an overall integration test coverage rate of an OTP application

parameters

Parameters

  • compile_time_source_lib_abs_path: source code project abs path in compile-time machine.
  • source_lib_absolute_path: source code project abs path in run-time machine.
Link to this function

post_app_cov_to_ci(url, extends_post_params, app_name)

Post run-time env elxiir application coverage to remote coverage service.

parameters

Parameters

  • app_name: application name, It is a string.
  • url: CI receive stats address
  • extends_post_params: use to transform stats which CI service can acceptable form
Link to this function

post_cov_stats_to_ud_ci(url, extends_post_params, compile_time_source_lib_abs_path \\ File.cwd!(), source_code_abs_path \\ File.cwd!())

Post coverage stats to User-Domain Cover CI Service.

parameters

Parameters

  • url: CI receive stats address
  • extends_post_params: use to transform stats which CI service can acceptable form
  • compile_time_source_lib_abs_path: source code project abs path in compile-time machine.
  • source_lib_absolute_path: source code project abs path in run-time machine.
Link to this function

reset_coverage_data()

Link to this function

start_app_cov(app_name)

Enable run-time env elxiir application coverage collection.

parameters

Parameters

  • app_name: application name, It is a string.