Correct _.template use in saucelabs.js.

This commit is contained in:
John-David Dalton
2014-06-19 10:45:08 -07:00
parent e0e4eed26b
commit ee267d23ba

View File

@@ -562,7 +562,7 @@ Job.prototype.remove = function(callback) {
_.defer(onRemove); _.defer(onRemove);
return; return;
} }
request.del(_.template('https://saucelabs.com/rest/v1/${user}/jobs/${id}', this), { request.del(_.template('https://saucelabs.com/rest/v1/${user}/jobs/${id}')(this), {
'auth': { 'user': this.user, 'pass': this.pass } 'auth': { 'user': this.user, 'pass': this.pass }
}, onRemove); }, onRemove);
}); });
@@ -622,7 +622,7 @@ Job.prototype.start = function(callback) {
return this; return this;
} }
this.starting = true; this.starting = true;
request.post(_.template('https://saucelabs.com/rest/v1/${user}/js-tests', this), { request.post(_.template('https://saucelabs.com/rest/v1/${user}/js-tests')(this), {
'auth': { 'user': this.user, 'pass': this.pass }, 'auth': { 'user': this.user, 'pass': this.pass },
'json': this.options 'json': this.options
}, _.bind(onJobStart, this)); }, _.bind(onJobStart, this));
@@ -644,7 +644,7 @@ Job.prototype.status = function(callback) {
} }
this._pollerId = null; this._pollerId = null;
this.checking = true; this.checking = true;
request.post(_.template('https://saucelabs.com/rest/v1/${user}/js-tests/status', this), { request.post(_.template('https://saucelabs.com/rest/v1/${user}/js-tests/status')(this), {
'auth': { 'user': this.user, 'pass': this.pass }, 'auth': { 'user': this.user, 'pass': this.pass },
'json': { 'js tests': [this.taskId] } 'json': { 'js tests': [this.taskId] }
}, _.bind(onJobStatus, this)); }, _.bind(onJobStatus, this));
@@ -675,7 +675,7 @@ Job.prototype.stop = function(callback) {
_.defer(onStop); _.defer(onStop);
return this; return this;
} }
request.put(_.template('https://saucelabs.com/rest/v1/${user}/jobs/${id}/stop', this), { request.put(_.template('https://saucelabs.com/rest/v1/${user}/jobs/${id}/stop')(this), {
'auth': { 'user': this.user, 'pass': this.pass } 'auth': { 'user': this.user, 'pass': this.pass }
}, onStop); }, onStop);