IDE Plugin for Automated Unit Test Selection

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Software developers face inefficiencies in identifying and executing relevant unit tests for modified code due to the large number of existing unit tests, often lacking complete understanding of which tests to run to qualify code changes.

Innovation Solution

A framework is introduced that automatically identifies and reports unit tests affected by code changes, utilizing a plugin architecture within an Integrated Development Environment (IDE) to determine changes, execute relevant unit tests, and generate test results, with features like preunitizer, unitizer, tester, and reviewer plugins to streamline the process.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If developers manually identify and execute unit tests for modified code, then they can ensure code quality, but the process becomes time-consuming and error-prone due to the large number of existing unit tests

Engineering Contradiction:
Improvecode quality assuranceVSAvoidtime to identify and execute unit tests
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent replaces the manual mechanical process of identifying and executing unit tests with an automated computational system. The framework uses static analysis, dependency graph construction, and algorithmic test selection to automatically determine which unit tests should be executed based on modified code, eliminating the need for developers to manually search through hundreds or thousands of unit tests while ensuring comprehensive quality assurance.

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

2Productivity

If developers rely on online documentation or personal knowledge to understand which unit tests to execute, then they can proceed with code changes, but the accuracy and completeness of test selection is insufficient

Engineering Contradiction:
Improvespeed of code modification processVSAvoidaccuracy of unit test identification
Core Design Contradiction:
ProductivityVSMeasurement precision

Solution Approach 1:

The patent implements a feedback mechanism where the system continuously analyzes modified code, updates the dependency graph, and provides accurate recommendations for unit test execution. The framework monitors code changes, traces dependencies through the codebase, and dynamically determines which unit tests are relevant, ensuring both speed and precision in test selection by providing real-time, context-aware guidance to developers.

Inventive Principle:
Principle #23Feedback

3Reliability

If all unit tests are executed for every code change, then complete quality assurance is achieved, but the process becomes inefficient and resource-intensive

Engineering Contradiction:
Improvecompleteness of quality assuranceVSAvoidefficiency of testing process
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent extracts and executes only the specific unit tests that are relevant to the modified code by analyzing dependencies and change impact. The system builds a dependency graph of the codebase, identifies which components are affected by modifications, and selectively executes only those unit tests that cover the changed areas, thereby maintaining complete quality assurance for modified code while avoiding the waste of time and resources that would result from executing all unit tests.

Inventive Principle:
Principle #2Taking out (Extraction)

Data Source

PatentUS10740222B2Intelligent unitizer test plug-in
Publication Date: 2020.08.11 SAP SE
  • US10740222B2 patent drawing
  • US10740222B2 patent drawing
  • US10740222B2 patent drawing

AI summary

A system and method for automatically identifying and reporting test units of computer-executable code corresponding to computer-executable code changes within an integrated development environment application so that the code affected by the code changes are tested by the determined test units. The determining of the test units corresponding to the code changes may include determining both direct affectations and indirect affectations to avoid unnecessary testing and an incomplete identification of unit tests.