White-box testing via function-to-test mapping

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current software testing methods are inefficient in identifying and addressing changes in code lines, leading to increased complexity and reduced effectiveness in data storage system testing.

Innovation Solution

A method and apparatus for white-box testing that determines changed code lines, identifies the corresponding functions, and selects relevant test cases based on a mapping from functions to test cases, utilizing a state machine to analyze function call relationships and update mappings for target code versions.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If traditional software testing methods are used, then testing coverage is maintained, but testing efficiency decreases and complexity increases

Engineering Contradiction:
Improvetesting efficiencyVSAvoidtesting complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent segments the testing process by dividing test cases into different levels (unit test cases, integration test cases, system test cases) and organizing them in a hierarchical structure. This segmentation allows the testing system to selectively execute only the necessary test cases based on code changes, rather than running all test cases, thereby improving testing efficiency while managing complexity through structured organization.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent implements preliminary action by pre-establishing a mapping relationship between code elements and test cases before actual testing occurs. The system pre-analyzes code dependencies and determines which test cases are associated with which code segments in advance. When code changes are detected, the system can immediately identify and execute only the relevant pre-mapped test cases, significantly reducing testing time and complexity.

Inventive Principle:
Principle #10Preliminary action

2Reliability

If all test cases are executed to ensure coverage, then testing effectiveness is maintained, but testing time increases

Engineering Contradiction:
Improvetesting effectivenessVSAvoidtesting time
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent applies partial action by executing only the necessary subset of test cases rather than all test cases. The system identifies code changes and selectively runs only the test cases that are directly affected by those changes, using pre-established mapping relationships. This partial execution approach maintains testing effectiveness for the changed portions while significantly reducing overall testing time by avoiding redundant execution of unrelated test cases.

Inventive Principle:
Principle #16Partial or excessive action

Solution Approach 2:

The patent replaces the mechanical approach of manually determining which test cases to run with an automated analysis system. The system uses computer-based code parsing, dependency analysis, and automated mapping to identify relevant test cases, substituting manual judgment and mechanical test execution with intelligent automated selection and execution, thereby reducing time loss while maintaining effectiveness.

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

3Measurement precision

If code changes are manually tracked, then change identification is achieved, but labor intensity increases and accuracy decreases

Engineering Contradiction:
Improvechange identification accuracyVSAvoidtracking system complexity
Core Design Contradiction:
Measurement precisionVSDevice complexity

Solution Approach 1:

The patent replaces manual code change tracking with an automated computer-based system that uses version control integration, code diff analysis, and automated parsing. The system automatically detects code changes by comparing different versions of the codebase, identifies affected code elements, and maps them to relevant test cases without human intervention. This substitution dramatically improves identification accuracy while the automated nature of the system actually reduces overall complexity compared to manual tracking processes.

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

Data Source

PatentUS10671518B2White-box testing
Publication Date: 2020.06.02 EMC IP HLDG CO LLC
  • US10671518B2 patent drawing
  • US10671518B2 patent drawing
  • US10671518B2 patent drawing

AI summary

Embodiments of the present disclosure provide a method, computer program product and apparatus for a white-box testing by determining a code line being changed in a target version of codes, determining a function to which the code line belongs, determining, based on a first mapping from functions to test cases, a set of test cases corresponding to the function to which the code line belongs, thereby enhancing efficiency of automatic testing.