cabbie-alpha
v1.0.1
Published
A webdriver client
Downloads
11
Readme
Cabbie
A node web-driver client
Installation
npm install cabbie
Usage
var assert = require('assert');
var cabbie = require('cabbie');
var driver = cabbie('http://localhost:4444/wd/hub', { browserName:'firefox' }, { mode: cabbie.Browser.MODE_SYNC });
var browser = driver.browser();
var activeWindow = browser.activeWindow();
// Set url and assert a header-text
activeWindow.navigator().setUrl('http://www.example.com');
assert.equal(activeWindow.getElement('h1').getText(), 'Example Domain');
// Click on element
activeWindow.getElement('h1').mouse().click();
// Click on a specific coordinate
activeWindow.mouse().clickAt(500, 200);
// Close active window
activeWindow.close();
driver.dispose();
Object Reference
License
MIT