Features
< Back to Blog Overview

TestingBot Tunnel

2012-04-04
Selenium Tunnel - Run Selenium tests on your staging environment.
  • Share on Facebook
  • Share on Twitter
  • Share on LinkedIn
  • Share on HackerNews
selenium tunnel

Today we are proud to release our new Selenium Tunnel, which will enable you to run Selenium tests on your local computer and network infrastructure.


Whether you want to test on your local computer (localhost), on a staging server inside your LAN, or on a computer across VPN, our new Tunnel makes all of this possible in a secure and reliable way.


Our previous solution, a simple SSH remote port forwarding program, allowed for testing on a single local computer and was at times slow. With the new Tunnel, we provide a more robust and faster solution. Here are a few of its features:

  • Run tests on your local computer, on computers inside your LAN or across VPN.
  • Fast: we cache static content on our end of the tunnel to reduce traffic inside the tunnel
  • Secure: when you start the Tunnel, a pristine VM server is booted just for you.
  • Robust: full HTTP(s) support, coded in Java
  • Easy: very simple setup

Run tests on your local computer

When running Selenium tests you might want to test against your local staging environment. Maybe you've updated some code or added a new feature and you want to make sure all regression tests still pass.


With the new Tunnel, you can easily test on http://localhost or http://10.0.1.5 without changing anything to your test code. The only thing you need to do is point your tests to http://127.0.0.1 port 4445 instead of http://hub.testingbot.com port 4444.


The Tunnel is a Java based program (jar) which contains our very own secure HTTP(s) proxy, which will relay requests to our grid. This way a browser on one of our instances can easily fetch webpages through the tunnel.

Fast

When booting the Tunnel, we boot up a fresh VM server just for you which is required to set up the tunnel. Booting this VM takes 45 seconds max.


After your tests are finished the tunnel and VM server will be destroyed.


At our end of the tunnel, we added an accelerator called Squid, which is used by a lot of trusted companies. Squid will keep a cache of the static content flowing through the tunnel and store it for the lifetime of the Tunnel.

When a test requests the same static content file multiple times it will never have to go through the tunnel as Squid will have it in its cache. This optimisation will make sure your Tunnel stays fast.

Secure

All the requests to and from our servers will pass through the Tunnel, which is based on SSH. The traffic flowing through your personal VM is only available to you.


When your tests are finished, the tunnel is destroyed together with everything on the VM server.

Robust

The Tunnel is built in Java with proven code and tests. We support both HTTP and HTTPS usage inside the tunnel.


Starting the tunnel happens with a simple command on the command line and offers options like verbose logging and fast-fail regexes.

Easy

Setting up the Tunnel is very easy. Download the JAR file from our website and run it on your command line: java -jar testingbot-tunnel.jar API_KEY API_SECRET


All you need to do is replace the API_KEY and API_SECRET with your own key and secret. You should see "You may start your tests" when your Tunnel is ready.


To use your Tunnel, you need to modify the host and port inside your test file(s). Instead of using our grid on http://hub.testingbot.com and port 4444, you now need to run your tests on http://localhost and port 4445. This will make sure your commands flow through the secure Tunnel, reaching our Selenium grid.


If you have any questions or suggestions, please leave a comment or reach out to us via email. Download our Selenium Tunnel.

TestingBot Logo

Sign up for a Free Trial

Start testing your apps with TestingBot.

No credit card required.

Other Articles

iPhone and iPad Selenium Testing with Webdriver

Since our last post announcing Mac OS X Selenium support, we now have added iPhone and iPad to the mix.

Read more
Mac OS X Selenium testing. Webdriver and Selenium RC testing with Apple.

We will make a lot of people happy with this announcement: today we start providing our customers with Mac OS X testing on-demand. Next to testin...

Read more
Samsung Galaxy Tab Testing with Selenium Webdriver

We are pleased to announce that we have added Samsung Galaxy Tab testing to our Selenium grid.

Read more
Selenium Testing on Linux Ubuntu

We are pleased to announce we now support Linux (Ubuntu 11.10) on our Selenium grid.

Read more
Website Monitoring and PageLoad Testing with Selenium

Next to running automated browser tests, Selenium and TestingBot can be used for other tasks like monitoring a website, or verifying that the pagel...

Read more
Run your Selenium tests in parallel with PHPUnit

One of the advantages of running your Selenium tests on the TestingBot grid is that we scale depending on your needs. If you need to run 100 Sele...

Read more