Skip to main content

Take control of a run in the live browser

When you execute a web Test Case, Thunders shows the run in a live browser and keeps it open after the run.

Written by Ines

When you execute a web Test Case in the Test Case Editor, Thunders shows the run in a live browser and keeps that browser open after the run. When the run waits for you, you can take control of the live browser: each action you take becomes a step of the Test Case at once. When a step that acts on the page fails, for example a click, typing text, a scroll or a selection, you can record the right action in place of the failed step and continue the run.

Prerequisites

  • Your Test Case is a web Test Case that runs on Chrome or Chromium, or a Mobile Test Case.

  • You work in the Test Case Editor. When you leave the page, the live browser closes.

1. Open the live browser

There are two ways to open the live browser.

Start a new Test Case from scratch

  1. In the Test Cases tab, click New Test Case, then Start from scratch.

  2. The Interactive session settings dialog opens. Select the Environment and the App, and set the Browser settings. Click Advanced settings for more options.

  3. Click Start session. The live browser opens on your app, and you have control of it.

If you click Cancel, the Test Case stays empty and nothing runs. You can then add steps by hand, or click the Record steps button of the empty Test Case to open the dialog again.

Execute an existing Test Case

Click Execute. The live browser opens when the run reaches its first browser step. While the run executes steps, you watch the browser but you cannot act in it. When the run ends, the browser stays open.

The address bar shows Live and a countdown: the time that remains before the live browser closes.

2. Take control of the browser

When nothing drives the browser, for example after a run or at a breakpoint, the bar above the browser says "Take control to click, type or fix something."

The live browser after a run, with the bar "Take control to click, type or fix something" and the Take control button
  1. Click Take control.

  2. Click, type and navigate in the live browser. The bar says "The browser records your steps." Each action becomes a step of the Test Case at once. The step shows as executed, with its screenshot.

  3. To use the browser without recording, turn off Record my actions. The bar then says "You use the browser without recording." Turn it on again to record.

  4. When you are done, click End Session, then Confirm. The browser closes, and the steps of the session stay saved in the Test Case. Click Keep session to continue instead.

At a breakpoint, the bar says "You have control" while you record. When you click Resume, the recording stops and the run continues after the steps that you recorded.

3. Edit the Test Case while the browser stays open

Adding, editing or deleting a step saves the Test Case. It never closes the browser or stops the run.

  • A step that you add at the end of the Test Case runs at once.

  • A step that you add in the middle of the Test Case is saved, and it waits for Resume: Resume replaces Execute, and the step runs when you click it. At a breakpoint, a step that you add before the breakpoint runs as soon as you save it, and the run waits at the breakpoint again.

  • When you save an edit to a failed step, the step runs again at once. If it passes, the run continues.

  • Execute and Restart run the Test Case from the first step, on the same browser.

To look at an earlier step, select it in the step list. The view shows the screenshot of that step, and the live browser stays open. Click Back to live to return to the live browser. You can also switch between Browser and Preview above the browser.

4. Manage the tabs of the live browser

While you record, the tab bar shows the tabs of the live browser, each with its title and icon. A tab that your app opens becomes the active tab. Each of these actions becomes a step, and it runs again the same way in a later run:

  • Click a tab to switch to it. The live browser shows that tab.

  • Click the cross of a tab to close it. You cannot close the first tab, because closing it ends the live browser.

  • Click the + button (Open a new tab), enter the address of the page, and click Open. When you enter an address with no https://, Thunders adds it.

  • Use the back, forward and reload arrows of the address bar.

The tab bar of the live browser with two tabs, the Thunders login page and Home | Thunders Help Center, the + button with its tooltip Open a new tab, and the address bar with Live and the time left

When Record my actions is off, these controls are locked, because no step would be saved.

5. Fix a failed step by recording it

When a step that acts on the page fails, for example a click, typing text, a scroll or a selection, the run waits for you. The bar says "Step N failed. Take control to click, type or fix something."

The bar "Step 6 failed. Take control to click, type or fix something", with the Take control and Ignore buttons
  1. Click Take control. The bar says "Recording steps ∙ Select the correct element to fix this step."

  2. In the live browser, perform the right action. You can record several actions, for example a scroll and then a click on the right button. The counter, for example 2 actions recorded, lists them when you hover over it.

  3. Click Fix & resume. The recorded steps replace the failed step, and the run continues from the next step on the same browser.

You have other options:

  • Click Cancel to drop the recorded actions. The failed step waits for you again.

  • Click Ignore to continue the run after the failed step. The step keeps its failure.

  • Edit the failed step instead. When you save the edit, the step runs again at once.

When another type of step fails, for example an assertion or an API call, or when the failed step comes from a reused Test Case, the bar says "Step N failed ∙ the run is waiting for you". For an assertion or an API call, it offers Edit manually. For a step of a reused Test Case, Edit manually is disabled: open that Test Case to edit it.

You fix one step at a time. When a later step fails, you start a new fix.

6. On a Mobile Test Case

On a Mobile Test Case, the same bar shows above the live device, and the device stays available between runs. Take control, Record my actions, Fix & resume, Ignore and Back to live work on the device as they do on the browser. The tab bar and the address bar are for web Test Cases only.

Frequently asked questions

How do I add steps after a run ends?

Click Take control in the bar above the live browser, then act in the browser. With Record my actions on, each action becomes a step at the end of the Test Case.

How do I continue a run past a failed step without fixing it?

When a step that acts on the page fails, click Ignore in the bar above the live browser. The run continues from the next step, and the failed step keeps its failure in the report.

How do I undo a fix that I am recording?

Click Cancel before you click Fix & resume. Thunders drops the recorded actions, and the failed step stays as it was.

How long does the live browser stay open?

The live browser stays open while the Test Case is open in the editor, for up to 15 minutes. The countdown in the address bar shows the time that remains. When you leave the page or click End Session, it closes. The steps that you recorded stay saved.

Which browsers show the live browser?

Chrome and Chromium. Select one of them in the Browser settings of the Test Case.

Related articles on this topic that you might find helpful

Did this answer your question?