Visual Studio platform Installation and testing

Source: Internet
Author: User

A. VS installation

Figure 1.1

Figure 1.2

Two. Unit Test exercises

Title: Textbook 22~25 page Unit test exercise

1. Create a C # class (as follows: Open VS2010, then click on the File button in the upper left corner of the VS interface, then click on File-New-project, a window will appear below. )

Figure 2.1

2. After the previous step is determined, the system automatically creates a C # window interface

                                                           ,         &NB Sp                          ,         &NB Sp   2.2                                                          ,         &N Bsp                                

3. Put the code of the textbook P22 page into test                             &NBS P                          ,         &NB Sp                          ,         &NB Sp                          ,         &NB Sp                          ,         &NB SP;

                                &N Bsp                          ,         &NB Sp                     2.3                                        ,         &N Bsp                          ,         &NB Sp                                

4. Mouse over the user class and right click on "Create Unit Test".

                                                           ,         &NB Sp                   2.4               &NBSP ;                          ,         &NB Sp                          ,         &NB Sp                            

5. Then click OK and the next new class will be

Figure 2.5

6. Fill in the code and get the unit tested.                          ,         &NB Sp                          ,         &NB Sp                          ,         &NB Sp                          ,         &NB Sp                                

                                                           ,         &NB Sp                          ,         &NB Sp                          ,         &NB Sp                                

Figure 2.6

7. Testing

Test list compiler, click Test, window.

Figure 2.7

8. Further testing.

Enter the code in the book to test, you can see the actual and expected differences.

Figure 2.7

9. The test results are as follows

Figure 2.8

Summary: The time spent on the test and VS installation process have spent a lot of time, through the Internet to find some new problems, I also learned a lot, but finally can not achieve running time calculation, not very clear, do not know what reason, I hope the teacher can point out my whole automatic test problem.

Visual Studio platform Installation and testing

Related Article

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.