Sunday, February 3, 2008

Load Testing on AJAX Application

Sometimes we need to perform a web test and load test for AJAX Application especially in partial postback.

VS 2005 Test edition / Team System provides a functionality to perform a web test. However the limitation is , it can not capture a partial postback.

For that reason we need one of the web capture tool called fiddler to capture all ajax request and response and we save it as Visual studio web test. and After that we can perform our ajax Load Test using VS 2005 Test edition / Team system.

Here are the steps

Before we perform load test, we need to create a web test first.

You may create multiple web tests to perform different scenario test cases.

In order to test an AJAX, you need to capture using Fiddler.

Here are the steps:

  1. Open Fiddler application.

  2. Open Internet Explorer and perform a scenario of your test. Fiddler will automatically log your request and response even for partial Post back /AJAX

  3. Select All fiddler capture session responses and requests

  4. On Fiddler menu File>Save>Session(s)>as Visual Studio Web Test

  5. Import this web test into your VS Test project.

  6. And it's ready to perform load test by creating a load test file inside VS
Note: You may set a windows credential in your web test.
  • There is an icon on the top tool bar of your web test.

No comments: