• Publicity: Public Only All

coverage-procs.tcl

Procs related to automated testing coverage

Location:
packages/acs-automated-testing/tcl/coverage-procs.tcl
Created:
2019-08-29
Author:
Héctor Romojaro
CVS Identification:
$Id: coverage-procs.tcl,v 1.1.2.14 2022/06/26 19:28:27 gustafn Exp $

Procedures in this file

Detailed information

aa::coverage::proc_coverage (public)

 aa::coverage::proc_coverage [ -package_key package_key ]

Calculates the test proc coverage of a particular package. If no 'package_key' is passed, then the system wide test proc coverage is returned.

Switches:
-package_key (optional)
The 'package_key' of the package to check.
Returns:
Dict with the number of procs (procs), covered procs (covered) and the coverage percentage (coverage).
Author:
Héctor Romojaro
Created:
2019-08-28

Partial Call Graph (max 5 caller/called nodes):
%3 test_aa__coverage_proc_coverage aa__coverage_proc_coverage (test acs-automated-testing) aa::coverage::proc_coverage aa::coverage::proc_coverage test_aa__coverage_proc_coverage->aa::coverage::proc_coverage aa::coverage::proc_list aa::coverage::proc_list (public) aa::coverage::proc_coverage->aa::coverage::proc_list packages/acs-automated-testing/www/admin/index.tcl packages/acs-automated-testing/ www/admin/index.tcl packages/acs-automated-testing/www/admin/index.tcl->aa::coverage::proc_coverage packages/acs-automated-testing/www/admin/proc-coverage.tcl packages/acs-automated-testing/ www/admin/proc-coverage.tcl packages/acs-automated-testing/www/admin/proc-coverage.tcl->aa::coverage::proc_coverage

Testcases:
aa__coverage_proc_coverage

aa::coverage::proc_coverage_level (public)

 aa::coverage::proc_coverage_level coverage

Calculates the level (high, medium, low...) of proc coverage from a particular value. This proc centralizes the levels for the different values, in order to keep consistency. Current values are: <25: very_low <50: low <75: medium <100: high 100: full

Parameters:
coverage (required)
The percentage of the procs covered by automated tests.
Returns:
A string (e.g: 'high')
Author:
Héctor Romojaro
Created:
2019-08-28

Partial Call Graph (max 5 caller/called nodes):
%3 test_aa__coverage_proc_coverage_level aa__coverage_proc_coverage_level (test acs-automated-testing) aa::coverage::proc_coverage_level aa::coverage::proc_coverage_level test_aa__coverage_proc_coverage_level->aa::coverage::proc_coverage_level packages/acs-automated-testing/www/admin/index.tcl packages/acs-automated-testing/ www/admin/index.tcl packages/acs-automated-testing/www/admin/index.tcl->aa::coverage::proc_coverage_level packages/acs-automated-testing/www/admin/proc-coverage.tcl packages/acs-automated-testing/ www/admin/proc-coverage.tcl packages/acs-automated-testing/www/admin/proc-coverage.tcl->aa::coverage::proc_coverage_level

Testcases:
aa__coverage_proc_coverage_level

aa::coverage::proc_covered_p (public)

 aa::coverage::proc_covered_p proc_name

Checks if the proc 'proc_name' is covered by any automated test.

Parameters:
proc_name (required)
The name of the proc to check.
Returns:
'true' if the proc is covered, 'false' otherwise.
Author:
Héctor Romojaro
Created:
2019-08-29

Partial Call Graph (max 5 caller/called nodes):
%3 test_aa__coverage_proc_proc_list_covered aa__coverage_proc_proc_list_covered (test acs-automated-testing) aa::coverage::proc_covered_p aa::coverage::proc_covered_p test_aa__coverage_proc_proc_list_covered->aa::coverage::proc_covered_p

Testcases:
aa__coverage_proc_proc_list_covered

aa::coverage::proc_list (public)

 aa::coverage::proc_list [ -package_key package_key ]

Creates a list of the procs belonging to a particular package, with its current automated testing covered status, excluding deprecated, callback contracts and not public procs. If no 'package_key' is passed, or the value of the provided package_key is an empty string, then the system wide test proc coverage is returned.

Switches:
-package_key (optional)
The 'package_key' of the package to check.
Returns:
List of dicts, each one with the following values: - package_key: the package key of the package, if the 'package_key' parameter is empty. - proc_name: the proc name. - covered_p: boolean, 'true' if the proc is covered by any automated test, false otherwise.
Author:
Héctor Romojaro
Created:
2019-08-29

Partial Call Graph (max 5 caller/called nodes):
%3 test_aa__coverage_proc_proc_list_covered aa__coverage_proc_proc_list_covered (test acs-automated-testing) aa::coverage::proc_list aa::coverage::proc_list test_aa__coverage_proc_proc_list_covered->aa::coverage::proc_list aa::coverage::proc_coverage aa::coverage::proc_coverage (public) aa::coverage::proc_coverage->aa::coverage::proc_list packages/acs-automated-testing/www/admin/proc-coverage.tcl packages/acs-automated-testing/ www/admin/proc-coverage.tcl packages/acs-automated-testing/www/admin/proc-coverage.tcl->aa::coverage::proc_list

Testcases:
aa__coverage_proc_proc_list_covered
[ show source ]