From 95db668c3c2b313ba01fed1c91b632996dbe757a Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Fri, 30 May 2014 10:03:06 -0400 Subject: [PATCH] Make `reError` more robust and leverage `console.log` sugar more. --- test/saucelabs.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/saucelabs.js b/test/saucelabs.js index 8009ed6de..155729cbf 100644 --- a/test/saucelabs.js +++ b/test/saucelabs.js @@ -53,7 +53,7 @@ var prevLine = ''; var push = Array.prototype.push; /** Used to detect error messages */ -var reError = /\berror\b/i; +var reError = /(?:\be|E)rror\b/; /** Used to detect valid job ids */ var reJobId = /^[a-z0-9]{32}$/; @@ -592,7 +592,7 @@ Job.prototype.restart = function(callback) { label = options.name + ':'; logInline(); - console.log(label + ' ' + description + ' restart %d of %d', ++this.attempts, this.retries); + console.log('%s %s restart %d of %d', label, description, ++this.attempts, this.retries); return this.remove(onGenericRestart); }; @@ -755,7 +755,7 @@ Tunnel.prototype.restart = function(callback) { this.restarting = true; logInline(); - console.log('Tunnel ' + this.id + ': restart %d of %d', ++this.attempts, this.retries); + console.log('Tunnel %s: restart %d of %d', this.id, ++this.attempts, this.retries); var jobs = this.jobs, active = jobs.active,