Поделиться через


How to: Play Back an Action Recording Using a Third-Party Web Browser

After you create an action recording, you can play it back when you run a test that contains the recording. This helps in circumstances where you might want to run the test multiple times because the action recording automatically plays back the steps. Alternatively, you can fast forward through the test steps until you reach the correct test step to verify a bug.

Note

For information about how to create an action recording, see How to: Create an Action Recording.

The action recording can also contain data that the tests steps use when the test runs, for example, logging on to an application or a Web site. As soon as the action recording finishes, you can continue to test manually at the point where the action recording stopped.

You can also play back your test using a different browser. This enables you to record your test with one browser and use the action recording to check it works correctly with a different browser.

Note

For a list of browsers supported for recording and playback, see Supported Configurations and Platforms for Coded UI Tests and Action Recordings. Coded UI tests use the same underlying technology as action recordings.

Note

By installing Microsoft Visual Studio 2010 Feature Pack 2, you can use Windows Internet Explorer 7 (or later versions) to record UI actions on a website or a Web-based application and then play back the tests using the Mozilla Firefox browser version 3.5 or 3.6. To download the feature pack, you must have either Visual Studio 2010 Ultimate, Visual Studio 2010 Premium or Test Professional 2010 with an MSDN subscription, Microsoft BizSpark, or MSDN Academic Alliance. For more information, see Recording Tests Using Windows Internet Explorer and Playing Back Using Mozilla Firefox and Microsoft Visual Studio 2010 Feature Pack 2.

The following procedure describes how to play back an action recording with a different browser, starting with how to load a test into Test Runner.

Replay an Action Recording Using a Different Browser

To play an action recording, you must first load a test that contains an action recording into Test Runner from Microsoft Test Manager. For more information, see How to: Create an Action Recording.

Loading a test with an action recording

Selecting test to run in Microsoft Test Manager

To load a test into Test Runner

  1. Open Microsoft Test Manager.

    Note

    To display the Microsoft Test Manager window, click Start, and then click All Programs. Point to Microsoft Visual Studio 2010 and then click Microsoft Test Manager 2010.

  2. On the center group switcher, click the down-arrow and then click Testing Center.

  3. On the center group menu bar, click Test.

  4. In the menu under the center group menu bar, click Run Tests if it is not already selected.

  5. In the left side pane, under Run Tests, select either the test plan or the test suite listed under the test plan that contains the test that you want to run.

    The right side pane displays the test cases in the selected test suite.

  6. In the right side pane, click a test case that contains an action recording and then click Run.

    The Test Runner opens.

    Note

    Select Run with options to specify a build to run the test on, or to override the test settings and environment settings for the test plan.

To use a different browser to play back an action recording

  1. When you load a test from Microsoft Test Manager into Test Runner, you are prompted to Start Test with the option Create action recording. Leave Create action recording clear and click Start Test.

  2. In the toolbar, click the down-arrow next to Play and select Change Browser for Playback.

    The Change browser for playback dialog box is displayed.

  3. Select the browser you want to use from Browser for playback.

    Note

    For a list of browsers supported for playback, see Supported Configurations and Platforms for Coded UI Tests and Action Recordings. Coded UI tests use the same underlying technology as action recordings.

  4. (Optional) If you want to always play back the action recordings with this browser for all tests, select Save this setting for all future action recordings.

  5. Click Save.

    Your action recording will now be played back with the selected browser if it is available on your computer.

  6. To play your action recording with this browser, click the down-arrow next to Play and select Play all.

    -or-

    Select a specific step or multiple steps in the test to play back, and in the toolbar click Play.

    The action recording will display the steps in the Automation Playback in Progress dialog box and the steps will play as you conducted them during the recording.

    Note

    You can preview the action recording steps before you run them by selecting the Preview option from the Play button in the toolbar. For more information, see How to: Preview Action Steps.

    After the action recording finishes, you can continue your testing with this manual test.

See Also

Tasks

How to: Create an Action Recording

How to: Preview Action Steps

Concepts

Recording and Playing Back Manual Tests