Application Testing Interface Subsection Assertion Strategy
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current application testing methods fail to thoroughly verify whether source code is correctly executed and functioning as intended, as code coverage metrics only indicate executed code without ensuring correctness.
Innovation Solution
The method involves extracting interface structures from source code, separating them into subsections, and using test code to perform primary tests, with assertion strategies evaluated against predefined requirements to generate measurement results, ensuring both execution and correctness of the source code.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Ease of operation
If code coverage metrics are used to measure testing completeness, then the ease of measuring test execution is improved, but the measurement precision of code correctness deteriorates
Solution Approach 1:
The patent segments the testing evaluation into multiple dimensions: code coverage metrics (measuring execution extent) and assertion strategy evaluation (measuring correctness). By dividing the single measurement task into separate components, each can be optimized for its specific purpose while contributing to an overall comprehensive evaluation.
2Productivity
If only code execution is tested, then the productivity of testing process is improved, but the reliability of source code verification deteriorates
Solution Approach 1:
The patent performs preliminary action by automatically generating assertion strategies and evaluation criteria before the actual testing execution. This preparation phase ensures that correctness verification is built into the testing process from the start, allowing both high productivity during execution and high reliability in verification results.
Solution Approach 2:
The patent implements feedback mechanisms where assertion results are evaluated against predefined requirements, and measurement results are generated that provide feedback on both execution coverage and correctness. This closed-loop feedback ensures that testing not only moves quickly but also verifies actual code correctness.
Data Source
AI summary
Application testing is disclosed in the present disclosure. An interface structure may be extracted from source code of an application under test (AUT), and the interface structure may be separated into subsections. Then a primary test may be performed for the AUT by using test code to execute the subsections. An assertion strategy in the test code may be evaluated based on a predefined assertion requirement to obtain a first measurement result of the AUT, in which the assertion strategy may be to assert an execution result of the test code executing the subsections.


