What would be the Regression Test?
Identify previously non-existent errors after code changes.
What Benefits of Doing Regression Testing?
Fiddle with the winning team and keep on winning.
What is this "regression" related to the test?
Regression is just something that worked and doesn’t work anymore, it’s going backwards, spoiling what was good. It’s a bug introduced by a later change in the code. No regression in initial development.
Explaining
This is effectively the most important test you have to formally perform. Without it you always run the risk of changing something and what worked stop working.
We can say that it is the opposite of TDD, although they do not oppose it, I say only in the sense that TDD cares about defining what it should do for later, and the regression test cares about ensuring that what has been done is always done like this.
It is especially useful in code bases that will be used publicly and/or on a large scale.
It’s common for us to use unit testing to establish regression testing. Regression testing is not a specific technique, it is a broader methodology that uses specific tools.
Another goal is to not let a found error occur again. So when a bug is found writes the unit test and it passes part of the regression test.
Unit testing is not the only technique. A load test can be a regression test. That it helps everything to work properly if the change made brought a loss of performance, scalability, etc.?
You know those sites that assess whether your code produced the right result and give you points? At least the most sophisticated are doing some sort of regression test. It has to give a specific output, in the specific time, with a specific consumption.
Regression testing can be fully automated and does not require special access to implementation details.
It gives you confidence to change the code, either by a requirement change, or by refactoring.
Testing without a clear purpose is not good for much. Even TDD, which I tend to be critical of most cases ,but not all of them, has a clear purpose, although I disagree that it is so useful or that they reach it with this tool. Regression testing has a clear purpose.
I say this because a lot of the tests they do out there have the purpose of doing tests. People don’t even know why they’re doing it, what they want to fight, what they solve, they don’t have a methodology for achieving results. I’m not saying it’s a waste of time, but I could be a better employee.
Briefly, the Regression Test is one of the main strategies to prevent Software Regression.
– Peter Krauss