Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

sc

Package Overview
Dependencies
Maintainers
5
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sc

Connect your machine to Sauce Labs.

  • 1.0.1
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
140
increased by12.9%
Maintainers
5
Weekly downloads
 
Created
Source

SC -- Sauce Connect in C (for node).


Update node to latest

  • http://nodejs.org/#download

Install libsauceconnect

  • (mac) brew install libsauceconnect (not yet ready)
  • (linux) apt-get install libsauceconnect (not yet ready)
  • (win) download msi installer (not yet ready)

Install

   $ npm install sc

Command line

  $ npm install -g sc
  $ sc --username yourusername --accessKey yourkeyhere

Authors

Writing a test!

  var wd = require('wd')
    , assert = require('assert')
    , sauceconnect = require('sc')
    , colors = require('colors')
    ;

  var obj = {
    username: process.env.SAUCE_USERNAME
    , accessKey: process.env.SAUCE_ACCESS_KEY
  };

  var connect = new sauceconnect(obj);

  connect.on('status', function(info) {
    console.log(info.green);
  });

  connect.start(function(err, session) {
    console.log(session);
    var browser = wd.promiseRemote("ondemand.saucelabs.com", 80, obj.username, obj.accessKey);

    browser.on('status', function(info) {
      console.log(info.cyan);
    });

    browser.on('command', function(meth, path, data) {
      console.log(' > ' + meth.yellow, path.grey, data || '');
    });

    browser.init({
        browserName: 'chrome',
        tags: ["examples"],
        name: "This is an example test"
    }).then(function () {
        return browser.get("http://google.com");
    }).then(function () {
        return browser.title();
    }).then(function (title) {
        assert.ok(~title.indexOf('Google'), 'Wrong title!');
    }).fin(function () {
        browser.quit(function() {
          session.stop(function(cObj) {
            console.log("Connect Session Stopped");
          });
        });
    }).done();

  });

License

FAQs

Package last updated on 16 Sep 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc