tests(web-inspector): add test for setImmediate polyfill#3670
tests(web-inspector): add test for setImmediate polyfill#3670patrickhulce merged 2 commits intomasterfrom
Conversation
ac6a84d to
7c0980b
Compare
| assert.ok(WebInspector.Color); | ||
| }); | ||
|
|
||
| it('does not destroy setImmediate', done => { |
There was a problem hiding this comment.
not immediately clear what's being tested here. Is this checking for the specific WebInspector (bad) setImmediate implementation?
There was a problem hiding this comment.
yes
does not break setImmediate
does not polyfill setImmediate incorrectly
any better?
There was a problem hiding this comment.
yeah, that helps, though maybe a comment about why arg.foo(); would throw, too :)
There was a problem hiding this comment.
also TIL setImmediate also exists on require('timers').setImmediate, so could check setImmediate === require('timers').setImmediate in addition to this functional test.
In theory someone could overwrite that as well, but they may deserve to screw things up by the time they reach that level of effort.
…e#3670) * tests(web-inspector): add test for setImmediate polyfill * change name, add comment
reminded by gitter to add test for this :)