node-BrowserStackTunnel
A Node.js wrapper for the BrowserStack tunnel client. On first run this will download the appropriate binary for your platform from BrowserStack. On Windows this will be a Jar file and you will need to have Java already installed.
http://www.browserstack.com/
Installation
npm install browserstacktunnel-wrapper
API
var BrowserStackTunnel = require('browserstacktunnel-wrapper');
var browserStackTunnel = new BrowserStackTunnel({
key: YOUR_KEY,
hosts: [{
name: 'localhost',
port: 8080,
sslFlag: 0
}],
osxBin: 'your_bin_dir',
linux32Bin: 'your_bin_dir',
linux64Bin: 'your_bin_dir',
win32Bin: 'your_bin_dir',
localIdentifier: 'my_tunnel',
v: true,
proxyUser: PROXY_USER,
proxyPass: PROXY_PASS,
proxyPort: PROXY_PORT,
proxyHost: PROXY_HOST,
force: false,
forcelocal: false,
onlyAutomate: false,
enableLoggingForApi: true
});
browserStackTunnel.start(function(error) {
if (error) {
console.log(error);
} else {
browserStackTunnel.stop(function(error) {
if (error) {
console.log(error);
} else {
}
});
}
});
Roadmap
Contributing
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using npm test
.
License
Copyright © 2014 Peter Halliday
Licensed under the MIT license.
17LtnRG4WxRLYBWzrBoEKP3F7fZx8vcAsK