testcafe-browser-provider-browserless

1.0.1 • Public • Published

testcafe-browser-provider-browserless

This is the browserless browser provider plugin for TestCafe.

NOTE: BETA! This plugin doesn't currently support the hosted service due to how the tests are ran (via a local web-server. Only use this plugin if your tests are network-accessible from where browserless is running!

Requirements

This module doesn't use a build-system, and does use async/await keywords, so at least Node > 8.x.x is required.

Install

npm install testcafe-browser-provider-browserless

Usage

When you run tests from the command line, use the provider name when specifying browsers:

testcafe browserless:chrome 'path/to/test/file.js'

You can specify where browserless is running by setting an enviroment variable of BROWSERLESS_URL:

BROWSERLESS_URL="ws://192.168.1.1:4000?token=YOUR-API-TOKEN-IF-SET" testcafe browserless:chrome 'path/to/test/file.js'

When you use API, pass the provider name to the browsers() method:

testCafe
    .createRunner()
    .src('path/to/test/file.js')
    .browsers('browserless:chrome')
    .run();

Author

Joel Griffith (https://browserless.io)

Package Sidebar

Install

npm i testcafe-browser-provider-browserless

Weekly Downloads

1

Version

1.0.1

License

MIT

Unpacked Size

2.93 kB

Total Files

3

Last publish

Collaborators

  • jgriffith