Udostępnij za pośrednictwem


How to: Configure Data Binding in a Web Test

Before you can add data binding to a Web request, you must add a data source to your Web test. For more information, see one of the following topics:

After you add a data source to a Web request, you can bind a Web test request to the data. For more information, see the following topic:

After you have bound a Web test to a data source, you must configure how many times you want the Web test to access the data. For example, if your data source contains 5,000 rows, you can first run the test using just 10 rows as a test. Then you can run the test using all the rows in the data source.

To configure data binding in a Web test

  1. On the Test menu, point to Edit Test Run Configurations, and then click Local Test Run.

    The localtestrun.testrunconfig dialog box appears.

    Note

    Instead of editing the Local Test Run configuration, you can also create a separate data run configuration for testing your data binding. Then you can switch between run configurations. For more information, see How to: Specify a Test Run Configuration.

  2. Select Web Test in the left pane.

  3. Click the One run per data source row option.

    - or -

    Click the Fixed run count option, and enter the number of rows of data to test.

    Note

    No matter which option that you select, the test will start on the first row of data and move sequentially through the data.

  4. Click Apply and then click Close.

  5. On the File menu, menu click Save to save the Web test.

See Also

Tasks

Walkthrough: Adding Data Binding to a Web Test

Walkthrough: Adding Data Binding to a Web Test (CSV File)

Walkthrough: Adding Data Binding to a Web Test (XML File)

Other Resources

Data Binding in Web Tests

Configuring Test Execution