Interpretation of code Daquan (9)

Source: Internet
Author: User

Interpretation of code Daquan (9)

 

If the previous chapter describes the specific creation process, chapter 24 "Review", chapter 25 "unit test", and Chapter 26 "debugging" focus more on the subsequent stages of the creation process.

There is nothing to say about the review. You can focus on the test. Unit Testing, function testing, partial testing, and system testing are all components. However, unit testing may be the most important part to improve code quality. A skilled craftsman always performs horizontal and vertical measurements with a flat scale and a lead hammer during wall building. This is also a unit test, so that it will not go wrong until the top of the building is enlarged. As for white box testing and black box testing, I would like to be familiar with computer courses. However, it may not be easy to write a good test code and data that covers possible data and processes. This is the basic skill of everyone. However, there are several basic principles to note: first, the boundary principle, second, abnormal data, and third, code that can never be executed. By the way, the recently promoted programming method is TDD (test driven develop), that is, test first development. First, write the test data and assertions, and then write the detailed code, if all the tests have been completed, the subprograms are also completed. However, I rarely see this method used for development on the Internet. I may have deleted these items when I published the Code. I am not very clear about this, but it seems to be a development direction of future programming.

Debugging is also an important topic in software development. Different debugging methods are available for different tools. Generally, it is easier for a veteran to locate the error location during the debugging process, while it takes more time for a novice. As a programmer, it is a necessary skill to be familiar with and master the debugging tools that are often used by the editor. Because different people use different tools, I don't want to talk too much. However, on csdn, I often see a friend posting a question about program exceptions. This is why debugging cannot be completed. I don't think there is any shortcut. I will spend some time debugging, debugging should not be difficult for you as long as you have written a certain amount of code.

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.