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

saucelabs

Package Overview
Dependencies
Maintainers
3
Versions
122
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

saucelabs - npm Package Compare versions

Comparing version 0.1.0 to 0.1.1

17

lib/SauceLabs.js

@@ -271,11 +271,16 @@ var crypto = require('crypto');

.on('end', function () {
var res;
try {
if (response.statusCode === 200) {
callback(null, JSON.parse(result));
} else {
callback(JSON.parse(result));
}
} catch (err) {
res = JSON.parse(result);
} catch (e) {
callback('Could not parse response: ' + result);
return;
}
if (response.statusCode === 200) {
callback(null, res);
} else {
callback(res);
}
});

@@ -282,0 +287,0 @@ });

@@ -5,3 +5,3 @@ {

"description": "A wrapper around Sauce Labs REST API",
"version": "0.1.0",
"version": "0.1.1",
"homepage": "https://github.com/holidayextras/node-saucelabs",

@@ -8,0 +8,0 @@ "repository": {

@@ -39,3 +39,3 @@ # node-saucelabs [![Build Status](https://secure.travis-ci.org/holidayextras/node-saucelabs.png)](http://travis-ci.org/holidayextras/node-saucelabs)

password: "your-sauce-api-key"
})
});

@@ -50,16 +50,18 @@ myAccount.getAccountDetails(function (err, res) {

console.log(res);
myAccount.getJobs(function (err, res) {
myAccount.getJobs(function (err, jobs) {
// Get a list of all your jobs
for (k in jobs) {
myAccount.showJob(jobs[k].id, function (err, res) {
var str = res.id + ": Status: " + res.status;
if (res.error) {
str += "\033[31m Error: " + res.error + " \033[0m";
}
console.log(str);
});
for (var k in jobs) {
if ( jobs.hasOwnProperty( k )) {
myAccount.showJob(jobs[k].id, function (err, res) {
var str = res.id + ": Status: " + res.status;
if (res.error) {
str += "\033[31m Error: " + res.error + " \033[0m";
}
console.log(str);
});
}
}
})
})
})
});
});
});
});

@@ -66,0 +68,0 @@ ```

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