Test Case To Code Mapping for Accurate Coverage
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing software testing methods fail to accurately determine which lines of code are uniquely executed by test cases, leading to incomplete code coverage and erroneous information, as traditional tools are often inaccurate, labor-intensive, and difficult to manage.
Innovation Solution
A system and method that uses a processor and memory to create and execute test cases, with a code coverage tool to monitor and determine Test Case To Code Mapping (TCTCM), indicating uniquely executed lines of code, thereby facilitating accurate code coverage data and optimization of test cases.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Measurement precision
If traditional tools are used to map test cases to code snippets, then the testing process can be performed, but the accuracy of code coverage determination is poor and the tools are labor-intensive
Solution Approach 1:
The system enables automated self-service by having the code coverage tool automatically monitor executed lines of code and generate TCTCM data without manual intervention. The processor automatically correlates test case execution with code coverage, eliminating the need for manual tracking and analysis while maintaining high accuracy.
Solution Approach 2:
The patent replaces manual mechanical processes with automated computational systems. Instead of manually tracking which test cases cover which code lines, the system uses a processor-executed program to automatically monitor, record, and correlate test case execution with code coverage data, substituting human labor with automated information processing.
2Reliability
If multiple test cases are created to cover all features, then feature coverage improves, but it becomes difficult to determine actual code coverage and avoid redundant testing
Solution Approach 1:
The system implements feedback by having the code coverage tool continuously monitor which lines of code are executed during test case runs and feed this information back to the TCTCM determination process. This feedback loop enables the system to track actual code coverage in real-time and use this information to identify gaps and redundancies in the test suite.
Solution Approach 2:
The patent introduces TCTCM (Test Case to Code Mapping) as an intermediary data structure that bridges test case execution and code coverage information. This intermediary layer systematically records and correlates which test cases execute which code lines, making the relationship between tests and covered code explicit and analyzable.
3Productivity
If 100 or 1000 test cases are created, then more features are tested, but the actual code coverage may only be 10% or 80% and some code snippets remain untested
Solution Approach 1:
The system replaces manual code coverage analysis with automated programmatic monitoring. The code coverage tool automatically instruments the code to track which lines are executed during test runs, and the processor automatically processes this data to determine precise code coverage metrics, eliminating the need for manual tracking even when dealing with large numbers of test cases.
Solution Approach 2:
The patent uses TCTCM as an intermediary mechanism that systematically captures the relationship between test case execution and code coverage. This intermediary structure enables precise measurement of actual code coverage by maintaining detailed records of which test cases execute which code lines, allowing accurate aggregation of coverage data across hundreds or thousands of test cases.
Data Source
AI summary
Disclosed is a system for determining one or more lines of code uniquely executed corresponding to a plurality of test cases executed on a computer program of an IT enabled application. The system creates a plurality of test cases (either manually or automatically). The system further enables a test case execution tool and a code coverage tool. The test case execution tool executes each of the plurality of test cases on the plurality of lines of code. On the other hand, the code coverage tool monitors the one or more lines of code, of the plurality of lines of code, executed for each test case. Subsequently, the system further determines Test Case To Code Mapping (TCTCM) indicating a subset, of the plurality of lines of code, executed at least once by the test case execution tool upon execution of one or more test cases of the plurality of test cases.


