The term Black Box is used to indicate a device which allows the user to verify that certain software and apps are carrying out the tasks and operations for which they were designed. This phase is the final check before distribution and sale.
Black Box Model: system theory and programming
The Black Box model has its origins in the world of programming and also involves system theory. Just like the black box from which it gets its name, it allows the user to verify, under certain specific conditions, whether certain previously theoretical results have in fact been produced.
All this takes place without the person verifying the precision of the results being able to view the internal processes inside the black box. This makes sense however, if we consider that when dealing with complex systems, it is better to take a macroscopic view rather than a detailed one.
In other words, the user should not focus on details relating to the operational processes, but rather on an analysis of the results obtained, which must correspond to those foreseen at the start of the planning phase.
We have already mentioned that this model also has applications in the world of programming. More specifically, these black boxes can analyse the algorithms which form a particular software, highlighting results which are closely dependent on the conditions defined by the programmer.
The professional in question must then verify that the results correspond to those he set out during the preliminary phase. It is essential to remember that software provided for the testing procedures uses a closed source code and that the person carrying out the checks cannot make any modifications.
In this way, it is possible to protect the code from potential plagiarism and avoid tampering, which could be used to falsify the results of the testing procedures.
Advantages of this model in programming
Thanks to the black box model, it is above all, possible to separate the tester from the code creator. The tester effectively operates from the standpoint of the end user. It is crucial to bear in mind that testing procedures may involve various different techniques.
Under certain circumstances, the input to be tested is divided into subgroups of data, so as to allow the tester to focus on each separate section. The process involves the following stages:
- Divide the software into equivalent classes (input value ranges) while analysing each section;
- Ascertain the presence of any errors among these input values;
- Carry out an analysis of data pairs, so as to keep bug parameters under control.
The technique described above is known as partition testing and is the most widely used and traditional technique in the field of Black Box Testing. During the partition testing phase, it is very important to define a model for the representation of the input data. This is known as an Input Domain Model and allows specific criteria to be applied to the generation of values. The IDM can be defined according to the interface being tested and its functions.
Another approach to testing involves the use of tests focusing on the analysis of a specific characteristic of the software. Also worthy of mention are regression tests.
Differences from the White Box model
The Black Box model is not the only one in the programming sector; there is also the White Box. In this case, this term refers to a testing procedure with diametrically opposite characteristics compared to those described above.
Using the White Box model, the tester considers the internal functioning of a software code or application, examining aspects which include memory capacity limits and the management of exceptions.
Translated by Joanne Beckwith