selenium-test-core

1.0.8 • Public • Published

selenium-test-core

NPM version Build Status

Test your application with selenium easily, without too much cofiguration and without having to install any drivers.

Installation

# Using npm
npm install --save selenium-test-core

Supported browsers

  • firefox
  • firefox:headless
  • chrome
  • chrome:headless
  • ie

Example

const {chooseUrlAndBrowser, takeScreenshot} = require('selenium-test-core');

(async() => {
    try {
        await chooseUrlAndBrowser(runTests);
    } catch (err) {
        process.exitCode = 1;
        console.log(err);
    }
})();

async function runTests(helpers) {
  await helpers.start();
  await takeScreenshot('welcome_page', helpers);

  // 2000 is the time to wait for closing the browser
  await helpers.close(2000);
}
# Using npm
npm start NAVIGATOR URL
# In headless
npm start NAVIGATOR:headless URL

Package Sidebar

Install

npm i selenium-test-core

Weekly Downloads

0

Version

1.0.8

License

MIT

Unpacked Size

8.47 kB

Total Files

12

Last publish

Collaborators

  • segandiaye