Delta Code Coverage Analysis for Software Testing
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing code coverage methods provide overall data that is not sufficient to identify potential risks of defects in large applications, as they do not focus on specific lines or branches that have changed between versions, making it difficult to achieve high code coverage efficiently.
Innovation Solution
A method and system for generating delta code coverage information on a line or branch level, including time-based and path-based delta code coverage, to focus testing efforts on changed areas, providing discriminated code coverage data.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If overall code coverage data is collected for all source code lines, then complete testing information is obtained, but it becomes difficult and time-consuming to analyze and identify high-risk areas in large applications
Solution Approach 1:
The patent segments the code coverage analysis by dividing source code into different versions (old version and new version) and further segmenting lines into changed and unchanged categories. This allows selective analysis of only the changed lines rather than processing entire codebases, thereby maintaining comprehensive coverage information while significantly reducing analysis time and complexity.
Solution Approach 2:
The patent extracts and isolates the changed lines of code between two versions, separating them from the unchanged portion. By extracting only the relevant changed lines for detailed analysis while treating unchanged lines as low-risk, the system focuses testing efforts on high-risk areas without losing overall code coverage context, thus resolving the contradiction between completeness and efficiency.
2Productivity
If testing effort is focused only on changed lines, then testing efficiency improves, but overall code coverage information may be lost
Solution Approach 1:
The patent applies local quality by providing different levels of analysis depth for different code regions. Changed lines receive detailed line-level or branch-level coverage analysis, while unchanged lines receive summary-level treatment. This differentiated approach maintains high testing efficiency for critical changed areas while preserving overall code coverage information through aggregated statistics and version-comparison capabilities.
Data Source
AI summary
The various embodiments herein disclose a system and method for generating a delta code coverage information. The system for generating delta code coverage information comprises, a source control module configured for storing a plurality of software program code files to be processed and a plurality of code coverage data corresponding to the plurality of software program code files, a processor configured to generate a delta code coverage data for analysis for each of the plurality of software program code files on a line level or at a branch level by performing a time based delta code coverage process and a path based delta code coverage process.


