Product developmentTesting approaches and practical techniques

Test design and techniques

5 minutes read

Testers use test design to create effective test scenarios and test cases to verify the functionality and performance of software. Test design allows you to maximize test coverage of functionality and detect serious defects in the application. In addition, the use of test design techniques reduces the number of tests performed and helps to ensure that important tests are not overlooked during testing.

What is a test design?

Test design is a stage of the software testing process where test cases are designed and created, according to previously defined quality criteria and test objectives.

Test design goals:

  • Maximize functionality coverage with tests.

  • Detect the most serious bugs.

  • Reduce the number of tests by eliminating unproductive test cases.

  • Don't miss important tests.

Boundary values

Boundary values is a method of checking the program behavior at input data which are on the boundaries of selected intervals. You should always check the boundary values because these are the places where errors most often appear. This is due to the fact that developers often make mistakes in such concepts as include/not include.

Let's look at a couple of simple and clear examples. There is a program, it has an input field, it accepts the value of a person's age and determines the age state according to the following algorithm:

  • 0 to 10 years – child.

  • From 11 to 18 years – teenager.

  • From 19 to 25 years – adult.

Let's test the interval for a child as an example. Accordingly, let's take the values on the boundaries.

Boundary values example

Based on the conditions of the task we will test the following values:

  • -1, 0, 1 – values on the left.

  • 9, 10, 11 – values on the right.

For the second interval:

  • 10, 11, 12 – values on the left.

  • 17, 18, 19 – values on the right.

The third interval is similar:

  • 18, 19, 20 – values on the left.

  • 24, 25, 26 – values on the right.

It is important to know one nuance. For instance, consider the expense of mobile communication, which amounts to $100. In other words, if we pay less, we might run short on funds, and if we pay more, it could lead to unnecessary expenses. In this case, it may seem that we should take the boundary values of 99, 100, 101, but it is not so. Since this is a currency, it includes cents. Therefore, the boundary values would be as follows: 99.99; 100; 100.01. That is, step/shift = 1 cent.

When defining the boundary values you need to consider the specifics of the data, whether it is speed, currency, temperature, etc., this determines what the step/shift will be.

Error guessing

This technique is based on experience. Its main purpose is to anticipate a possible error. For example, the documentation says that the user's email should be entered in the email field. The tester thinks: "I should enter a non-existent email" or "I'll enter my grandmother's number. I should get an error here".

State and transition diagram

One of the simplest design test techniques, the essence of which is to describe specific application states and how they can change. Thanks to transition and state diagrams, we can visually see future tests. Everyone has probably studied flowcharts in school, but if you haven't, no worries. Let's familiarize ourselves with the basic common concepts:

  • Start point – the black point.

  • Transition – an arrow representing transition from one state to another.

  • State – a circle denoting the application state in which it expects an event.

  • End point – looks like a white circle in a black circle.

Let's analyze everything in the example of an ATM, namely the algorithm of getting access to the account.

State and transition diagram example

Now let's visualize the scenarios for testing on the scheme:

Visualisation of state and transition diagram

Conclusion

Several test design techniques are discussed in this topic. However, these are not all the techniques that can help a tester in his work. There are several more of them, which will be discussed in the next topic.

9 learners liked this piece of theory. 0 didn't like it. What about you?
Report a typo