Free cookie consent management tool by TermsFeed Policy Generator

source: trunk/sources/HeuristicLab.Persistence/3.3/Tests/AuthoringTests.txt @ 6349

Last change on this file since 6349 was 1614, checked in by epitzer, 16 years ago

Transform console tests into unit tests (#593)

File size: 6.6 KB
Line 
1==========================================================================
2    Visual Studio Team System: Overview of Authoring and Running Tests   
3==========================================================================
4
5This overview describes the features for authoring and running tests in
6Visual Studio Team System and Visual Studio Team Edition for Software Testers.
7
8Opening Tests
9-------------
10To open a test, open a test project or a test metadata file (a file with
11extension .vsmdi) that contains the definition of the test. You can find
12test projects and metadata files in Solution Explorer.
13
14Viewing Tests
15-------------
16To see which tests are available to you, open the Test View window. Or,
17if you have installed Team Edition for Software Testers, you can also open
18the Test List Editor window to view tests.
19
20To open the Test View window, click the Test menu, point to Windows, and
21then click Test View. To open the Test List Editor window (if you have
22installed Team Edition for Software Testers), click Test, point to Windows,
23and then click Test List Editor.
24
25Running Tests
26-------------
27You can run tests from the Test View window and the Test List Editor window.
28See Viewing Tests to learn how to open these windows. To run one or more
29tests displayed in the Test View window, first select the tests in that
30window; to select multiple tests, hold either the Shift or CTRL key while
31clicking tests. Then click the Run Tests button in the Test View window
32toolbar.
33
34If you have installed Visual Studio Team Edition for Software Testers, you can
35also use the Test List Editor window to run tests. To run tests in Test List Editor,
36select the check box next to each test that you want to run. Then click the
37Run Tests button in the Test List Editor window toolbar.
38
39Viewing Test Results
40--------------------
41When you run a test or a series of tests, the results of the test run will be
42shown in the Test Results window. Each individual test in the run is shown on
43a separate line so that you can see its status. The window contains an
44embedded status bar in the top half of the window that provides you with
45summary details of the complete test run.
46
47To see more detailed results for a particular test result, double-click it in
48the Test Results window. This opens a window that provides more information
49about the particular test result, such as any specific error messages returned
50by the test.
51
52Changing the way that tests are run
53-----------------------------------
54Each time you run one or more tests, a collection of settings is used to
55determine how those tests are run. These settings are contained in a “test
56run configuration” file.
57
58Here is a partial list of the changes you can make with a test run
59configuration file:
60
61 - Change the naming scheme for each test run.
62 - Change the test controller that the tests are run on so that you can run
63   tests remotely.
64 - Gather code coverage data for the code being tested so that you can see
65   which lines of code are covered by your tests.
66 - Enable and disable test deployment.
67 - Specify additional files to deploy before tests are run.
68 - Select a different host, ASP.NET, for running ASP.NET unit tests.
69 - Select a different host, the smart device test host, for running smart device unit tests.
70 - Set various properties for the test agents that run your tests.
71 - Run custom scripts at the start and end of each test run so that you can
72   set up the test environment exactly as required each time tests are run.
73 - Set time limits for tests and test runs.
74 - Set the browser mix and the number of times to repeat Web tests in the
75   test run.
76
77By default, a test run configuration file is created whenever you create a
78new test project. You make changes to this file by double-clicking it in
79Solution Explorer and then changing its settings. (Test run configuration
80files have the extension .testrunconfig.)
81
82A solution can contain multiple test run configuration files. Only one of
83those files, known as the “Active” test run configuration file, is used to
84determine the settings that are currently used for test runs. You select
85the active test run configuration by clicking Select Active Test Run
86Configuration on the Test menu.
87
88-------------------------------------------------------------------------------
89
90Test Types
91----------
92Using Visual Studio Team Edition for Software Testers, you can create a number
93of different test types:
94
95Unit test: Use a unit test to create a programmatic test in C++, Visual C# or
96Visual Basic that exercises source code. A unit test calls the methods of a
97class, passing suitable parameters, and verifies that the returned value is
98what you expect.
99There are three specialized variants of unit tests:
100 - Data-driven unit tests are created when you configure a unit test to be
101   called repeatedly for each row of a data source. The data from each row
102   is used by the unit test as input data.
103 - ASP.NET unit tests are unit tests that exercise code in an ASP.NET Web
104   application.
105 - Smart device unit tests are unit tests that are deployed to a smart device
106   or emulator and then executed by the smart device test host. 
107
108Web Test: Web tests consist of an ordered series of HTTP requests that you
109record in a browser session using Microsoft Internet Explorer. You can have
110the test report specific details about the pages or sites it requests, such
111as whether a particular page contains a specified string.
112
113Load Test: You use a load test to encapsulate non-manual tests, such as
114unit, Web, and generic tests, and then run them simultaneously by using
115virtual users. Running these tests under load generates test results,
116including performance and other counters, in tables and in graphs.
117
118Generic test: A generic test is an existing program wrapped to function as a
119test in Visual Studio. The following are examples of tests or programs that
120you can turn into generic tests:
121 - An existing test that uses process exit codes to communicate whether the
122   test passed or failed. 0 indicates passing and any other value indicates
123   a failure.
124 - A general program to obtain specific functionality during a test scenario.
125 - A test or program that uses a special XML file (called a “summary results
126   file”), to communicate detailed results.
127
128Manual test: The manual test type is used when the test tasks are to be
129completed by a test engineer as opposed to an automated script.
130
131Ordered test: Use an ordered test to execute a set of tests in an order you
132specify.
133
134-------------------------------------------------------------------------------
135
136
Note: See TracBrowser for help on using the repository browser.