Selenium Test Automation in the Cloud On 1500+ Browsers
Products
Resources
Sign Up

Inside A Selenium Script

Breaking It All Down, In JavaScript

Selenium can be intimidating for many novice programmers & testers. But, at it's heart, it is a simple set of commands that mimic user behavior and allow us to click, type, scroll, and gesture our way to a high-quality web experience.

Preview image
  • More info

    Importing Selenium & Connecting To Our Hub

    This is the beginning of our entire script. It imports the required packages we need like Selenium WebDriver itself and connects to our remote hub! If you are familiar with Selenium Grid, you'll notice it works very similarly.
    Learn More About Installing Selenium.

    Close
  • More info

    Our Test Capabilities

    Here we'll choose what browser, OS, and resolution we'd like to run our Selenium test on. We can also record a video of our script here.

    Close
  • More info

    Setting Up Your Authentication

    You'll need to have a working username and authkey to get into our hub, so head on over your Account and grab your information. If you don't have one currently, you can sign up for a 7-day free trial.

    Close
  • More info

    Our Actual Test Case

    Alright, now that we have all that other stuff done and out of the way, here is the meat of the entire Selenium script. The test case itself. It all of it's glory it does 4 things. It goes to a URL, clicks a button, fills out a form, then clicks another button.

    Close
  • More info

    Our Test Assertion

    This is our the thing we actually want to test. We're making sure the title of the page in this case is equal to "Selenium Test Example Page"

    Close