Misplaced Pages

Regression testing: Difference between revisions

Article snapshot taken from Wikipedia with creative commons attribution-sharealike license. Give it a read and then ask your questions in the chat. We can research this topic together.
Browse history interactively← Previous editNext edit →Content deleted Content addedVisualWikitext
Revision as of 09:12, 31 March 2004 edit64.217.81.37 (talk)No edit summary← Previous edit Revision as of 23:30, 26 May 2004 edit undo209.71.217.227 (talk)No edit summaryNext edit →
Line 13: Line 13:
<I>Remaining questions - who invented the term? Who was the first to use it systematically?</I> <I>Remaining questions - who invented the term? Who was the first to use it systematically?</I>


As a consequence of the introduction of new bugs, program maintenance requires far more system testing per statement written than any other programming. Theoretically, after each fix one must run the entire back of test cases previously run against the system, to ensure that it has not been damaged in an obscure way. In practice, such <i>regression testing</i> must indeed approximate this theoretical idea, and it is very costly. -- Fred Brooks, Mythical Man Month (p 122) As a consequence of the introduction of new bugs, program maintenance requires far more system testing per statement written than any other programming. Theoretically, after each fix one must run the entire batch of test cases previously run against the system, to ensure that it has not been damaged in an obscure way. In practice, such <i>regression testing</i> must indeed approximate this theoretical idea, and it is very costly. -- Fred Brooks, Mythical Man Month (p 122)

Revision as of 23:30, 26 May 2004

Regression testing is any type of software testing which seeks to uncover regression bugs. Regression bugs occur whenever software functionality that previously worked stops working. Typically regression bugs occur as an unintended consequence of program changes.

Common methods of regression testing are re-running previously run tests and checking whether previously-fixed faults have reemerged.

Experience has shown that as software is developed, this kind of reemergence of faults is unfortunately quite common. Sometimes it occurs because a fix gets lost through poor revision control practices (or simple human error in revision control), but just as often a fix for a problem will be "fragile" - if some other change is made to the program, the fix no longer works. Finally, it is not unknown that when some feature is redesigned, the same mistakes will be made in the redesign that were made in the original implementation of the feature.

Therefore, in most software development situations it is considered good practice that when a bug is located and fixed, a test that exposes the bug is recorded and regularly reperformed after subsequent changes to the program. Some projects (Mozilla, I think does it) even set up automated systems to automatically re-run all regression tests at specified intervals (usually daily or weekly) and report any regressions. Or, if you are using make, you could set up your makefile to automatically run the regression tests after every successful compile.

Regression testing is an integral part of the extreme programming software development methodology. There design documents are replaced by extensive, repeatable and automated testing of the entire software package at every stage in the software development cycle.

Regression means to step backward. When software changes are made that break stuff that used to work, it is considered to regress. Regression is the opposite of progress.

Remaining questions - who invented the term? Who was the first to use it systematically?

As a consequence of the introduction of new bugs, program maintenance requires far more system testing per statement written than any other programming. Theoretically, after each fix one must run the entire batch of test cases previously run against the system, to ensure that it has not been damaged in an obscure way. In practice, such regression testing must indeed approximate this theoretical idea, and it is very costly. -- Fred Brooks, Mythical Man Month (p 122)