Cloud native EDA tools & pre-optimized hardware platforms
Discover how the Full-Expectation-Yet (FEY) Approach revolutionizes software testing by focusing on outputs and behavior validation. By ensuring the presence of expected values, this approach enhances test coverage, reliability, and overall software quality. Dive into the key insights, challenges, and benefits of implementing the FEY Approach to unlock the true potential of your testing efforts.
In the realm of software testing, one common challenge is the oversight of defining expected values for every input during test creation. This can lead to incomplete or ineffective test coverage, resulting in undetected issues slipping through the cracks. In this article, we will explore the underlying problems causing this issue and introduce a solution that addresses these challenges.
Specification Gaps: Not every edge case or scenario is explicitly described in the software specification, leaving room for being potentially overlooked during test creation.
Loss of Test Validity: As software undergoes changes, tests may become outdated and lose their relevance, making it difficult to determine their accuracy through visual inspections alone.
Complexity of Software Interfaces: Software systems often have numerous interfaces, making it challenging to define clear expected values for each input at every point in time.
Overwhelming Automation Projects: In large-scale automation projects, testers may overlook situations or test vectors where expected values have not been defined, resulting in incomplete testing coverage.
A Solution: Adding an Additional Monitoring Layer
To address these challenges, we propose implementing an additional monitoring layer that ensures the presence of expected values for each interface.
This is achieved through the creation of a dedicated variable for each interface, initialized with a default value of ¡°false.¡± This variable is then explicitly and automatically highlighted in the test report. If an expected value is not defined at any given point in a test, the test will automatically fail. This enables testers to quickly identify scenarios, inputs, or situations where expected values have not been defined after each test run.
The approach of focusing on outputs in testing is particularly suitable for:
Safety-Critical Industries: Industries such as automotive, medical, aerospace, and other safety-critical domains where the correct behavior and accuracy of software outputs are of utmost importance.
Development Teams with Complex Software: Teams working on software projects with intricate functionalities, numerous interfaces, and complex calculations that require thorough testing and validation of outputs.
Test Managers and Engineers: Professionals responsible for ensuring the quality and reliability of software through effective testing strategies. This approach provides them with a systematic method to monitor and verify the expected outputs.
Quality Assurance Teams: QA teams seeking to enhance their testing processes by incorporating a comprehensive approach that covers both inputs and outputs, thereby improving the overall test coverage and effectiveness.
Test Automation Experts: Experts in test automation who aim to leverage automation tools and techniques to streamline and optimize the testing process, with a specific focus on outputs and behavior validation.
The evaluation of outputs/calculations of software forms the core of testing. Whether a test case passes or fails solely depends on the expected values, as these values define the expected behavior of the software. Hence, it is crucial to describe these expected values as comprehensively as possible.
To better understand this fact, here is a short side note
Basic principle in test automations:
Disadvantage of this reasonable logic with a short example:
For a test object with many outputs (and thus functional calculations) a test case is created. The test case contains many test conditions (steps) and stimulates the test object for many situations (high coverage). Now the problem: The test case contains only insignificantly relevant assessments concerning the behavior. Thus, it will be reported as successful, even if the test has very low content or no significance.
This is very unfavorable. But there is a solution for this. We call this approach Full-Expectation-Yet.
The Full-Expectation-Yet (FEY) Approach in a nut shell:
A check variable is created for each output of the system under test. The purpose of the variable is to check whether there is an expected value for an output of a test object at any time.
For each sample (test vector with input data) the default value of the test variable is therefore false. The default value is set to true only if there is a specified expected value of the output.
FYI: In TPT, assessment can be defined in test data independent, custom entities. Assessments are automatically run after test execution.
An evaluation of the variable is automatically performed to generate the report. If there are time intervals (samples) in which no expected values are present, the variable retains the default value (false) and the test case fails. In this case, expected values are missing for the test object, which can be supplemented by the tester.
3 steps to implement the FEY Approach:
The Result:
Since for each output a variable initially has the value False and is only set to true if there is a test of the output, tests fail if there are stimulations of the test object that show a behavior that has not (yet) been specified in the test.
To check as many situations as possible, we recommend using the code coverage metric Modified-Condition-Decision-Coverage (MC/DC).
Real-World Example:
To showcase the practicality and effectiveness of the FEY Approach, let¡¯s consider an example in the automotive industry. Imagine a development team working on an advanced driver assistance system (ADAS) for a self-driving car.
By implementing the FEY Approach, the team can create dedicated variables for each output, such as collision detection, lane departure warnings, and adaptive cruise control. With clear expected values defined for each output, the team can comprehensively test the behavior and accuracy of these critical functionalities.
This ensures that the ADAS system performs reliably, providing enhanced safety for passengers and other road users. Such examples highlight the tangible benefits and real-world application of the FEY Approach in industries where software behavior is of utmost importance.
This methodical approach ensures that:
Important: In the current implementation there is no direct coupling between outputs and the test variables. The implementation must therefore be checked for incorrect use in the course of a review.
What do you need for implementation?
All you need is a test automation with the following functionalities:
Reference implementation using the example of Lights Control:
Connect your System under Test
Strengths of the FEY Approach
Weaknesses of the FEY Approach
In this article, we explored the challenges associated with defining expected values in software testing and introduced a solution called Full-Expectation-Yet (FEY) Approach. The core of testing lies in evaluating the outputs and calculations of the software, and the presence of expected values is crucial in determining the success or failure of test cases.
The FEY Approach addresses the shortcomings of traditional testing methods by adding an additional monitoring layer. It involves creating dedicated variables for each output of the system under test, initialized with a default value of ¡°false.¡± These variables are then evaluated during test execution, and if an expected value is not defined, the test case fails. This approach ensures that all situations and outcomes are covered in the tests, providing a systematic method to monitor and verify the expected outputs.
The FEY Approach is particularly suitable for industries with safety-critical developments, development teams working on complex software projects, test managers and engineers responsible for ensuring quality, and quality assurance teams seeking to enhance their testing processes. By focusing on outputs and behavior validation, this approach improves the overall test coverage, effectiveness, and reliability.
While the FEY Approach offers several strengths, such as ensuring test validity and detecting specification gaps, it also has weaknesses. Misuse of the implementation, failure to detect contradictory requirements, and limited consideration of parameterizations are some of the challenges that need to be addressed.
By implementing the FEY Approach, software testing can be revolutionized, leading to more comprehensive and effective testing practices that contribute to improved software quality and reliability.