Although VSTS can be used to record WebTests there is added benefit of using HTTP proxy in that process as explained here.
Following is a general guide on how to use Fiddler to record a WebTest for use in VSTS performance testing:
- Start fiddler
- Make sure that fiddler is in “Capturing” mode (bottom left corner)
- Lunch web browser and navigate to any page
- Check Fiddler window; if no request is recorded make sure fiddler plug-in is turned on in the browser. Alternatively web browser proxy settings can be configured manually to 127.0.0.1 and port 8888
- Delete all requests from the Fiddler using Remove->All menu option
- Switch to the “Request Builder” tab on the right side, type in comment for the next step in the business process (e.g. navigate to application homepage) and click execute button.
This will result in an incorrect (red) http request recorded by Fiddler which is expected.
The purpose of this procedure is to add a comment to the recorded script. Once the script is exported into VSTS those invalid requests will be replaced with comments.
Although there is comment functionality already build-in Fiddler it is awkward to use. Fiddler comments will not be visible in Fiddler and they will only appear when the webtest is opened in VSTS
- Refer to the business process script and perform action in the web browser (e.g. navigate to the login page, login, logout, etc.)
Add a new comment each time a new request(s) is recorded. It is common for a single button click to generate many requests.
- Repeat steps 6-8 to complete business process
- Switch to Fiddler and click “Capturing” icon in the left bottom corner to stop recording
For the full guide to developing VSTS WebTests please refer to the Using Fiddler with VSTS.