Has it happened to you that with the release of a new version of your favorite application some feature disappeared? Or it works but unexpected things happen when you execute it? Or does it just crash?
Today we will see what the possible tests that guarantee to avoid all of this are: regression tests.
You still don’t know what regression testing is?
There are many rules for testing software, and you may be surprised to learn that there’s even the documentation job of testing software.
*I leave you here a few seconds to surprise you…
And not only that, my friend, there are international organizations that are devoted to studying and making general recommendations.
*For example, standards ISO/IEC 29119 roughly state what software testing processes should be.
For several decades I have been fascinated by all these processes, including monitoring industrial devices, to such an extent that I stick so much to them that they always call me a perfectionist, me!
I will remind you that the design and construction of any machinery, even today, is carried out by human beings whose lives depend on their proper functioning!
Cars, air conditioners, power plants that cool homes in hot summer…
For that reason software tests must be adapted to the work itself that these programs will carry out:
- A program to automatically fly an airplane? Rest assured that you will be subjected to very thorough testing.
- A banking software? It will be tested and will have a special section for testing the corresponding audit software.
- A video game software? No one will die if something goes wrong, worst case scenario players will buy the game from the competition, but who wants that, gamer fella’?
That is why I would like to explain to you, in the simplest possible way, what these processes and tests are all about.
Unit tests, re-approval and reanalysis
Let’s quickly see some key concepts:
- Unit tests:
Unlike the last century, we have better hardware at our disposal, which allows for automated, full and fast tests, which can be reused again and again (and run independently) for the source code itself.
A comma, a pair of parentheses may be misplaced or well placed depending on the version of the programming language used (for example, see in Python the command print). For this, unit tests are performed.
- Process of reapproval:
When a software is modified, whatever the reason, each and every one of the points that have been worked on must be reapproved.
Said tests are always done manually.
- Reanalysis process:
If the previous point is suspended, the software will be returned to the development department specifying what its malfunctions are.
Once they have been corrected and delivered, they will be reanalyzed and, if everything’s correct, they will be reapproved.
No more preambles! What is a regression test?
Regression tests are totally different from the previous tests.
They are called that way because they come from the principle that if a software works as expected, and is altered either internally or externally, then you have to make sure that it returns to its previous stability state.
*When we say that a software is stable and works as designed, we are talking about everything as a whole, overall.
Therefore, a regression test must be applied to each and every component.
As you can imagine, this is a titanic task, but if done well, it will help improve user experience and gain customer confidence.
When to perform a regression test?
When a new feature is added to a software, the reapproval and reanalysis tests are performed, a regression test must be performed before delivering it to the customer.
And also when:
- The requirement changes or was misunderstood by developers and then a feature has to be “repaired”.
- The software has passed a regression test, is delivered and works very well until something changes.
*For example, the user has upgraded the operating system or migrated to a newer version: the program suffers a bug that needs to be fixed.
- The software does its job but over time data accumulates and it takes more and more time to execute the same tasks.
Optimizing the source code is then required and the entire test cycle is repeated again.
- Depending on each country there will be new legislation and the software will have to comply with the extremes of law. In this case the software is refurbished and a regression test will be necessary before being re-legalized.
- You need to port the software to a different operating system (e.g. GNU/Linux® to MS Windows®) in order to sell it to more customers. Here the same regression tests will also be copied and adapted to the new environment.
Some disadvantages of this type of regression test
Not everything was going to be good news:
- The slightest change has to be tested in a regression test.
Even without any changes in the source code of the software.
- As monitoring works, there will be simple and some more complex features, which can be a problem if you have a time limit.
For example, monitoring a web page can take milliseconds if it is about doing a ping or getting a specific value, but in the case of user experience monitoring you will have to record each of the tests to be performed.
- Once you have automated regression testing you may need to perform a manual test, this will result in more time and money being spent.
Programador desde 1993 en KS7000.net.ve (desde 2014 soluciones en software libre para farmacias comerciales en Venezuela). Escribe regularmente para Pandora FMS y ofrece consejos en el foro. También colaborador entusiasta en Wikipedia y Wikidata.
Machacador de hierros en gimnasios y cuando puede se ejercita en ciclismo también. Fanático de la ciencia ficción.
Programmer since 1993 in KS7000.net.ve (since 2014 free software solutions for commercial pharmacies in Venezuela). He writes regularly for Pandora FMS and offers advice in the forum. Also an enthusiastic contributor to Wikipedia and Wikidata.
Crusher of irons in gyms and when he can he exercises in cycling as well. Science fiction fan.