test-agent
Advanced tools
Comparing version 0.1.0 to 0.1.1
@@ -0,1 +1,6 @@ | ||
# 0.1.1 | ||
- Syntax errors that occur during the run will now also cause | ||
a test error. | ||
# 0.1.0 | ||
@@ -2,0 +7,0 @@ - Added much better remote console.log by using node's console.log code. |
@@ -51,2 +51,5 @@ var Proxy = require(__dirname + '/runner-stream-proxy'), | ||
} | ||
if(data.event === 'end'){ | ||
this.emit('end', this); | ||
} | ||
return this.proxy.respond([data.event, data.data]); | ||
@@ -53,0 +56,0 @@ }; |
@@ -40,2 +40,3 @@ var Reporter = require(__dirname + '/../mocha/reporter'); | ||
this.reporter = new Reporter(options); | ||
this.isRunning = false; | ||
} | ||
@@ -57,6 +58,11 @@ | ||
this.reporter.on('start', this._onRunnerStart.bind(this, server)); | ||
this.reporter.on('end', this._onRunnerEnd.bind(this, server)); | ||
}, | ||
_onError: function _onError(data) { | ||
this.savedError = data; | ||
if (this.isRunning) { | ||
this.emitSyntaxError(data); | ||
} else { | ||
this.savedError = data; | ||
} | ||
}, | ||
@@ -114,4 +120,9 @@ | ||
_onRunnerEnd: function _onRunnerEnd(server, runner) { | ||
this.isRunning = false; | ||
}, | ||
_onRunnerStart: function _onRunnerStart(server, runner) { | ||
server.emit('test runner', runner); | ||
this.isRunning = true; | ||
if (this.savedError) { | ||
@@ -118,0 +129,0 @@ this.emitSyntaxError(this.savedError); |
{ | ||
"name": "test-agent", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"author": "James Lal", | ||
@@ -5,0 +5,0 @@ "description": "execute client side tests from browser report back to cli", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
438379
14809