mirror of
https://github.com/ariya/phantomjs.git
synced 2024-10-26 14:29:13 +03:00
Small test suite improvements:
* handle failures reported by done() correctly * support valgrind as a debugger
This commit is contained in:
parent
9ac8cccf0a
commit
476b7b9401
@ -760,6 +760,8 @@ class TestRunner(object):
|
||||
return ["gdb", "--args", self.phantomjs_exe]
|
||||
elif debugger == "lldb":
|
||||
return ["lldb", "--", self.phantomjs_exe]
|
||||
elif debugger == "valgrind":
|
||||
return ["valgrind", self.phantomjs_exe]
|
||||
else:
|
||||
raise RuntimeError("Don't know how to invoke " + self.debugger)
|
||||
|
||||
|
@ -785,6 +785,8 @@ Test.prototype.fail = function fail(message) {
|
||||
Test.prototype.done = function done() {
|
||||
var i;
|
||||
|
||||
this.in_done = true;
|
||||
|
||||
if (this.timeout_id !== null) {
|
||||
clearTimeout(this.timeout_id);
|
||||
this.timeout_id = null;
|
||||
|
Loading…
Reference in New Issue
Block a user