Automatic screening for unrelated regression testing
To achieve a new function, or to fix a bug, developers often need to make changes to existing code, and when a developer changes part of the code, he often needs to run all of the unit tests again to make sure that his changes do not have a "butterfly effect", Which leads to unexpected problems. If it's late in the project, even a mid-sized system might have thousands of unit tests, running thousands of unit tests, probably a few hours faster. In fact, every time the impact of code churn is limited, a single code change may also affect several, more than 10, and up to dozens of unit tests. Every time you change the code, you run the thousands of unit tests again, even though the machines run automatically, but it's also a waste. So is there any way to save this part of the wasted time?
VS 2010 provides a feature called "Test Impact Analysis", which has been translated into "testing impact analyses" and I think it seems more appropriate to "test implicated analysis." With this capability, developers can easily pick up tests that are really affected by this code change and filter out most irrelevant tests when they are finished modifying code and going to unit regression testing. Assuming that a developer modifies only one method in a class, he only needs to pass "test Impact analysis" to pick out the possible 三、五个 unit test and run it again (refer to Figure 1), Without having to run all the relevant or unrelated unit tests as usual.
Fig. 1 Modified Method (1) and its "Contagion" test (1)
This feature is also useful for manual testers, especially when manual testers are doing regression testing (refer to Figure 2), and are running all test cases again, Or just pick out the test cases that are affected by the code churn (where the change refers to all the code changes from the last Test build to the one that was measured). The answer is yes, now that we have a "test implicated analysis", why do we have to roamed?
Figure 2: Only Test runs that have been "implicated" in code changes are selected for regression testing