firecrown.fctools.coverage_summary ================================== .. py:module:: firecrown.fctools.coverage_summary .. autoapi-nested-parse:: Comprehensive tool to analyze test coverage output in JSON format. This tool provides a detailed analysis of test coverage including: - Overall coverage summary - Per-file coverage breakdown - Detailed information about untested lines and branches - Files with less than perfect coverage Attributes ---------- .. autoapisummary:: firecrown.fctools.coverage_summary.app Classes ------- .. autoapisummary:: firecrown.fctools.coverage_summary.CoverageSummary firecrown.fctools.coverage_summary.FileIssue Functions --------- .. autoapisummary:: firecrown.fctools.coverage_summary.analyze_coverage_json firecrown.fctools.coverage_summary.print_coverage_summary firecrown.fctools.coverage_summary.print_file_issues firecrown.fctools.coverage_summary.print_perfect_coverage_files firecrown.fctools.coverage_summary.main Module Contents --------------- .. py:class:: CoverageSummary Summary statistics for coverage analysis. .. py:attribute:: total_files :type: int :value: 0 .. py:attribute:: files_with_perfect_coverage :type: int :value: 0 .. py:attribute:: files_with_missing_lines :type: int :value: 0 .. py:attribute:: files_with_missing_branches :type: int :value: 0 .. py:attribute:: files_with_excluded_lines :type: int :value: 0 .. py:attribute:: overall_line_coverage :type: float :value: 0.0 .. py:attribute:: overall_branch_coverage :type: float :value: 0.0 .. py:attribute:: total_statements :type: int :value: 0 .. py:attribute:: total_missing_lines :type: int :value: 0 .. py:attribute:: total_excluded_lines :type: int :value: 0 .. py:attribute:: total_branches :type: int :value: 0 .. py:attribute:: total_missing_branches :type: int :value: 0 .. py:class:: FileIssue Information about coverage issues in a specific file. .. py:attribute:: file_path :type: str .. py:attribute:: line_coverage :type: float .. py:attribute:: branch_coverage :type: float .. py:attribute:: missing_lines_count :type: int .. py:attribute:: missing_branches_count :type: int .. py:attribute:: excluded_lines_count :type: int .. py:attribute:: missing_lines :type: list[int] .. py:attribute:: missing_branches :type: list[list[int]] .. py:attribute:: excluded_lines :type: list[int] .. py:attribute:: total_statements :type: int .. py:attribute:: total_branches :type: int .. py:function:: analyze_coverage_json(console, coverage_file) Analyze coverage data from a JSON file. .. py:function:: print_coverage_summary(console, summary) Print overall coverage summary. .. py:function:: print_file_issues(console, file_issues, show_source = True) Print detailed information about files with coverage issues. .. py:function:: print_perfect_coverage_files(console, file_issues, all_files) Print files with perfect coverage. .. py:data:: app .. py:function:: main(coverage_file = typer.Argument(..., exists=True, file_okay=True, dir_okay=False, readable=True, resolve_path=True, help='Path to the coverage JSON file to analyze'), show_source = typer.Option(False, '--show-source', help='Show source code for missing lines'), show_perfect = typer.Option(False, '--show-perfect', help='Show files with perfect coverage')) Analyze test coverage output in JSON format. This tool provides a detailed analysis of test coverage including overall coverage summary, per-file breakdown, detailed information about untested lines and branches, and files with imperfect coverage.