test: increase test coverage for cancelling timers#10068
Closed
lrlna wants to merge 4 commits intonodejs:masterfrom
Closed
test: increase test coverage for cancelling timers#10068lrlna wants to merge 4 commits intonodejs:masterfrom
lrlna wants to merge 4 commits intonodejs:masterfrom
Conversation
Contributor
Fishrock123
suggested changes
Dec 1, 2016
| // This test makes sure clearing timers with | ||
| // 'null' or no input does not throw error | ||
|
|
||
| assert.doesNotThrow(() => { clearInterval(null);}); |
Contributor
There was a problem hiding this comment.
These arrow functions would be a bit cleaner without the braces, e.g. assert.doesNotThrow(() => clearInterval(null));
Contributor
|
Seems good otherwise! |
addaleax
approved these changes
Dec 2, 2016
cjihrig
reviewed
Dec 2, 2016
|
|
||
| assert.doesNotThrow(() => clearTimeout()); | ||
|
|
||
| assert.doesNotThrow(() => clearInterval(null)); |
Contributor
There was a problem hiding this comment.
Is there a reason you're testing intervals twice? Should these be immediates?
cjihrig
approved these changes
Dec 2, 2016
Fishrock123
approved these changes
Dec 2, 2016
Contributor
|
@lrlna If you could squash the commits into one that would be great. :D Otherwise we'll just do it before landing. |
targos
approved these changes
Dec 3, 2016
silverwind
approved these changes
Dec 3, 2016
Contributor
|
Thanks! Landed in e21e129. |
silverwind
pushed a commit
that referenced
this pull request
Dec 3, 2016
Add a test for cancelling timers with null or no arguments. PR-URL: #10068 Reviewed-By: Myles Borins <myles.borins@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Roman Reiss <me@silverwind.io>
addaleax
pushed a commit
that referenced
this pull request
Dec 5, 2016
Add a test for cancelling timers with null or no arguments. PR-URL: #10068 Reviewed-By: Myles Borins <myles.borins@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Roman Reiss <me@silverwind.io>
addaleax
pushed a commit
to addaleax/node
that referenced
this pull request
Dec 8, 2016
Add a test for cancelling timers with null or no arguments. PR-URL: nodejs#10068 Reviewed-By: Myles Borins <myles.borins@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Roman Reiss <me@silverwind.io>
jmdarling
pushed a commit
to jmdarling/node
that referenced
this pull request
Dec 8, 2016
Add a test for cancelling timers with null or no arguments. PR-URL: nodejs#10068 Reviewed-By: Myles Borins <myles.borins@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Roman Reiss <me@silverwind.io>
MylesBorins
pushed a commit
that referenced
this pull request
Dec 20, 2016
Add a test for cancelling timers with null or no arguments. PR-URL: #10068 Reviewed-By: Myles Borins <myles.borins@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Roman Reiss <me@silverwind.io>
MylesBorins
pushed a commit
that referenced
this pull request
Dec 21, 2016
Add a test for cancelling timers with null or no arguments. PR-URL: #10068 Reviewed-By: Myles Borins <myles.borins@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Roman Reiss <me@silverwind.io>
MylesBorins
pushed a commit
that referenced
this pull request
Dec 21, 2016
Add a test for cancelling timers with null or no arguments. PR-URL: #10068 Reviewed-By: Myles Borins <myles.borins@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Roman Reiss <me@silverwind.io>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Checklist
make -j8 test(UNIX), orvcbuild test nosign(Windows) passesAffected core subsystem(s)
tests
Description of change
This PR tests cancelling timers with
null, or no arguments do not throw an error.