Use VS 2010 to improve the level of automation of software testing (4)

Source: Internet
Author: User

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

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.