Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

Commit

Permalink
test: Timeout#unref() does not return instance
Browse files Browse the repository at this point in the history
Timeout#unref() call returns undefined, not this. The test already
worked before, because the interval was still unref'd, and the test also
succeeds without clearing the interval.

PR-URL: #9171
Reviewed-by: Colin Ihrig <cjihrig@gmail.com>
Reviewed-by: Timothy J Fontaine <tjfontaine@gmail.com>
  • Loading branch information
jscissr authored and trevnorris committed Feb 11, 2015
1 parent 8d8a2f2 commit d2b5461
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion test/simple/test-timers-unref.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ setTimeout(function() {
interval = setInterval(function() {
unref_interval = true;
clearInterval(interval);
}, SHORT_TIME).unref();
}, SHORT_TIME);
interval.unref();

setTimeout(function() {
unref_timer = true;
Expand Down

0 comments on commit d2b5461

Please sign in to comment.