Testing Bot

Testing Bot is a cloud provider. It requires a monthly or yearly subscription, but offers free plans for open source projects.

Start by signing up for an account at testingbot.com, then set the following environment variables:

Your testing bot key.
Your testing bot secret.

To do this locally, you can create a .env file in your project's root directory:

TESTINGBOT_KEY={your testing bot key}
TESTINGBOT_SECRET={your testing bot secret}

Then you can test using code like:

import assert from 'assert';
import cabbie from 'cabbie-sync';

// connect to testingbot, adding {debug: true} makes cabbie log each method call.
const driver = cabbie('testingbot', {debug: true});

try {
  // navigate to a url in the currently active window

  // get an element, and check that its text equals some expected value
    'Example Domain',
} finally {
  // whether tests pass or fail, dispose of the driver