If you are using Visual Studio team test edition, there is a feature called webtest. These tests can easily be recorded in Visual studio and then be played back on a server.
1) Just write your test in visual studio in the test project. If you dont see the web test menu, you don’t have team test
2) You can generate code from any web test . Once you are in the code you have access to everything.
3) If you have multiple developers in a project, fix the port number of you web project to same port. This way all developers will run the same port and your web test will also run. If you are running under IIS, then you are ok.
4) You can launch the inbuilt Visual Studio server with this command
start /B webdev.webserver.exe /port:3799 /path:ACTUAL PATH OF WEB PROJECT /VPATH:/WEBROOT
ex start /B webdev.webserver.exe /port:3234 /path:C:\projects\src\XYZWeb /VPATH:/XYZWeb
Your URL might have looked like
http://localhost:3234/XYZWeb
5) Then cd to the root of the source , where you see a vsmdi file. This will be where your solution file is. and run mstest
MSTest /testmetadata:XYZ.vsmdi /testlist:mytests
testlist are a way to arrange the tests you want to run. You will see these under the test menu in Visual Studio.
There are some issues around the way mstest produces output directories. If you want to merge the output to your cruisecontrol server, you could just pipe the output to a text file. Make sure you delete any old directories. Look at mstest /help.
6) The visual studio server ( that icon you see on the taskbar ) is actually a windows application and I havefound noeasy way to kill this from command line I mean there is no /stop option
The only way i found was
taskkill /IM webdev.webserver.exe


