Features
< Back to Blog Overview

Flaky Selenium tests

2015-09-28
  • Share on Facebook
  • Share on Twitter
  • Share on LinkedIn
  • Share on HackerNews

Today TestingBot has added a new feature that should help you debug issues you encounter when running automated tests.


Suppose you're running a test and you notice something isn't quite working well (AJAX request is failing, Javascript errors, ...).

When this happens, it'd be easy to simply pause the test, log in on the pristine virtual machine and start debugging with mouse and keyboard straight from your browser. You could fire up Developer Tools and inspect the javascript errors, or inspect the Ajax requests for problems.


With our new breakpoint feature, you can pause a running test at any time and immediately control the browser with your mouse and keyboard.


When your test starts running, it will appear in our member dashboard.

Navigating to the test detail page, you will see a "Breakpoint/Pause" button, if you click that the test will be paused and you will be able to control the browser from that page.


If you're looking to pause a test from within your test, that's possible as well. Suppose you're writing a test and need to inspect the browser at a specific point in your test, you can send TestingBot a command to pause the test.

Once the command is sent, you navigate to the test detail page and can immediately control the browser for debugging.

Copy code
require "rubygems"
require "selenium-webdriver"
require "selenium/client"

caps = {
  :browserName => "internet explorer",
  :version => "10",
  :platform => "WIN8"
}

urlhub = "http://key:secret@hub.testingbot.com/wd/hub"
client = Selenium::WebDriver::Remote::Http::Default.new
client.timeout = 120

@webdriver = Selenium::WebDriver.for :remote, :url =&gt; urlhub, :desired_capabilities =&gt; caps, :http_client =&gt; client
@webdriver.manage.window.resize_to(800, 600)
@webdriver.navigate.to "https://testingbot.com"
if @webdriver.title != "TestingBot"
  # something is not right, pause this test so we can inspect on TestingBot

  @webdriver.execute_script("testingbot: break")
end
@webdriver.quit

We hope this new feature will help you with your Selenium tests. If you have any comments or suggestions, please let us know!

TestingBot Logo

Sign up for a Free Trial

Start testing your apps with TestingBot.

No credit card required.

Other Articles

blank

With Robot Framework you can build easy to read test cases, which can then be run via Selenium WebDriver on our Selenium Grid. It allows using ke...

Read more
blank

This week we've been adding many more browser versions to our list of browsers you can pick from. You can now instantly launch a Chrome browser ...

Read more
blank

Windows 10 is now available on TestingBot to use during both manual and automated testing (Selenium WebDriver). This is the latest OS version avai...

Read more
blank

With our TestingBot Tunnel you can easily and securely test your websites running on your local computer or internal network. When you download a...

Read more
New design for our Manual Testing Service

Today we're introducing a new design for our Manual Testing Service.

Read more
blank

Today we've updated our TestLab, where you can upload your Selenium IDE tests and schedule test-runs, with 2 new features. The first new feature ...

Read more