Difference between revisions of "VS 2008"
From Richard's Wiki
(→Adding Console Output to Load Tests running Unit Tests) |
(→Adding Console Output to Load Tests running Unit Tests) |
||
Line 23: | Line 23: | ||
=== Adding Console Output to Load Tests running Unit Tests === | === Adding Console Output to Load Tests running Unit Tests === | ||
− | * [http://blogs.msdn.com/billbar/pages/adding-console-output-to-load-tests-running-unit-tests.aspx adding-console-output-to-load-tests-running-unit-tests] - This is not trivial, requires adding code to unit tests to save console output to SQL Server. VS2010 supports saving logging information from unit tests when run as load tests. | + | * [http://blogs.msdn.com/billbar/pages/adding-console-output-to-load-tests-running-unit-tests.aspx adding-console-output-to-load-tests-running-unit-tests] - This is not trivial, requires adding code to unit tests to save console output to SQL Server. VS2010 supports saving logging information from unit tests when run as load tests, so the problem goes away. |
=== Snippets === | === Snippets === |
Latest revision as of 18:16, 6 January 2010
When creating a "Test" project in Visual Studio, the following element
is added to the csproj xml in the very first PropertyGroup element:
<ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
If you created your test assembly by hand, say by creating a new Class Library
and adding a reference to Microsoft.VisualStudio.QualityTools.UnitTestFramework,
this element will not be in your csproj file and visual studio will ignore all
the tests located inside. Add the element and all will be good again.
- Install VS2008 under Windows 7 x64 [1]:
1. If you have McAfee virus software make sure on access scan is turned off. This may also be true for other virus scanning software but I’m sure you’ll let me know. 2. Do not let the DVD load with auto-play. 3. Right click setup.exe then properties. 4. Click the Compatibility tab. 5. Click the check box next to “Run this program in compatibility mode for:” 6. Select Windows Vista (Service Pack 1). 7. Click the check box under Privilege Level “Run this program as administrator” 8. Double Click the setup and away you go. Select whatever options you want to install it works with any as I found out. Some people only could get it to work with a Common or Full installs. This method seems to work with any.
Adding Console Output to Load Tests running Unit Tests
- adding-console-output-to-load-tests-running-unit-tests - This is not trivial, requires adding code to unit tests to save console output to SQL Server. VS2010 supports saving logging information from unit tests when run as load tests, so the problem goes away.
Snippets
Unzip this & add the contents to My Documents\Visual Studio 2008\Code Snippets\Visual C#\My Code Snippets
- Media:singleton.zip - VS2008 snippet to create a singleton class.