Automated MC/DC Test Data Generation via Code Abstraction

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current methods for generating test data for Modified Condition/Decision Coverage (MC/DC) are manual, time-consuming, and prone to human errors, especially for complex and large programs, and existing tools may produce false positives using static analysis, necessitating a dynamic and automated approach.

Innovation Solution

An automated system for generating test data that optimizes and abstracts program code, inserts annotations, and uses model checkers to generate traces and test data, ensuring MC/DC compliance across function-based, module-based, and sub-system levels, with feedback on metric compliance.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If manual methods are used to generate test data for MC/DC, then developers can identify and cover code segments, but the process is tedious and time-consuming

Engineering Contradiction:
ImproveMC/DC coverageVSAvoidtime-consuming
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The system performs self-service by automatically generating test data without requiring manual developer intervention. The automated test data generation system analyzes the program code, identifies conditions and decisions, and generates test cases that satisfy MC/DC criteria autonomously, eliminating the tedious manual process while maintaining coverage reliability

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The manual mechanical process of developers creating test cases is replaced by an automated computational system. The system uses program analysis algorithms, condition tracking mechanisms, and automated test case generation to substitute the manual mechanical process, significantly reducing time while maintaining the reliability of MC/DC coverage

Inventive Principle:
Principle #28Mechanics substitution (Replace mechanical system)

2Reliability

If manual test case development is used, then code coverage can be achieved, but human errors are prone

Engineering Contradiction:
ImproveMC/DC coverageVSAvoidaccuracy
Core Design Contradiction:
ReliabilityVSMeasurement precision

Solution Approach 1:

The system eliminates human error by performing self-service through automated analysis and generation. The automated system consistently applies MC/DC criteria without human oversight, ensuring that test data generation is free from the errors that inevitably occur in manual processes, thereby improving both reliability and measurement precision

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The system implements feedback mechanisms where test data generation is continuously validated against MC/DC criteria. The system monitors whether generated test cases satisfy the coverage requirements and automatically adjusts or regenerates test data if criteria are not met, ensuring high accuracy and eliminating human error through iterative verification

Inventive Principle:
Principle #23Feedback

3Productivity

If static analysis tools are used, then test data generation is automated, but false positives are produced

Engineering Contradiction:
ImproveautomationVSAvoidaccuracy
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The system transitions from static analysis to dynamic test data generation. Instead of statically analyzing code without execution, the system generates actual test cases and executes them against the program, observing real runtime behavior. This dynamic approach maintains automation productivity while eliminating false positives by verifying coverage through actual execution rather than static assumptions

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

The system performs preliminary actions by generating and executing test cases before final verification. It proactively creates test data that targets specific conditions and decisions, executes them to observe actual program behavior, and uses this empirical evidence to confirm MC/DC coverage, thereby avoiding false positives that static analysis cannot detect

Inventive Principle:
Principle #10Preliminary action

4Productivity

If existing automated tools are used, then test data generation is faster, but they may produce false positives using static analysis

Engineering Contradiction:
ImprovespeedVSAvoidaccuracy
Core Design Contradiction:
ProductivityVSMeasurement precision

Solution Approach 1:

The system maintains the speed advantage of automation by using efficient algorithms for test case generation while transitioning to dynamic execution-based verification. This allows rapid generation of test data followed by quick execution and validation, achieving both high productivity and measurement precision by eliminating false positives through actual program execution rather than static analysis

Inventive Principle:
Principle #15Dynamics

Data Source

PatentUS8612938B2System and method for automatic generation of test data to satisfy modified condition decision coverage
Publication Date: 2013.12.17 TATA CONSULTANCY SERVICES LTD
  • US8612938B2 patent drawing
  • US8612938B2 patent drawing
  • US8612938B2 patent drawing

AI summary

The tool, MC/DC-Automatic Tool Generator automatically generates test data to satisfy Modified Condition Decision Coverage (MCDC) from input code/model. This tool reduces the effort required to generate MCDC test data significantly. In order to reduce the time required by model checkers, abstraction and optimization methodologies have been implemented to analyze typical reactive software model/code.