FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

test_runner: add support for mocking setImmediate timer by ErickWendel · Pull Request #49397 · nodejs/node · GitHub

/ node Public

test_runner: add support for mocking setImmediate timer - #49397

Merged
nodejs-github-bot merged 5 commits into
nodejs:mainfrom
ErickWendel:test_runner/add-setImmediate-to-mock-timers
Aug 31, 2023
Merged

test_runner: add support for mocking setImmediate timer#49397
nodejs-github-bot merged 5 commits into
nodejs:mainfrom
ErickWendel:test_runner/add-setImmediate-to-mock-timers

Conversation

ErickWendel commented Aug 29, 2023
edited
Loading

Copy link
Copy Markdown
Member

This PR adds support for

  • - setImmediate
  • - timers.setImmediate
  • - timers.promises.setImmediate

This PR makes sure that setImmediate has priority higher than setTimeout and follows the spec defined in the docs about:
When multiple calls to setImmediate() are made, the callback functions are queued for execution in the order in which they are created

cc: @nodejs/test_runner

ErickWendel self-assigned this Aug 29, 2023

nodejs-github-bot commented Aug 29, 2023
edited by ErickWendel
Loading

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/test_runner

nodejs-github-bot added needs-ci PRs that need a full CI run. test_runner Issues and PRs related to the test runner subsystem. labels Aug 29, 2023
ErickWendel changed the title test_runner: add support for setImmediate test_runner: add support for mocking setImmediate timer Aug 29, 2023
Comment thread doc/api/test.md Outdated
Comment thread doc/api/test.md
Co-authored-by: CW <cwunder@gnome.org>
Comment thread doc/api/test.md Outdated
Signed-off-by: Erick Wendel <erick.workspace@gmail.com>
Signed-off-by: Erick Wendel <erick.workspace@gmail.com>
ErickWendel requested review from ljharb and ovflowd August 29, 2023 18:06
tniessen added the experimental Issues and PRs related to experimental features. label Aug 29, 2023
Comment thread doc/api/test.md Outdated
ErickWendel added request-ci Add this label to start a Jenkins CI on a PR. commit-queue Add this label to land a pull request using GitHub Actions. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. labels Aug 30, 2023
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Aug 30, 2023

Copy link
Copy Markdown
Collaborator

Co-authored-by: Jordan Harband <ljharb@gmail.com>
Co-authored-by: Moshe Atlow <moshe@atlow.co.il>
ErickWendel force-pushed the test_runner/add-setImmediate-to-mock-timers branch from c1323df to 962e14a Compare August 30, 2023 17:04
ErickWendel added request-ci Add this label to start a Jenkins CI on a PR. and removed commit-queue Add this label to land a pull request using GitHub Actions. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. labels Aug 30, 2023
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Aug 30, 2023

Copy link
Copy Markdown
Collaborator

Copy link
Copy Markdown
Collaborator

atlowChemi added the author ready PRs that have at least one approval, no outstanding review comments, and a CI started. label Aug 31, 2023
atlowChemi added commit-queue Add this label to land a pull request using GitHub Actions. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. labels Aug 31, 2023
nodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label Aug 31, 2023
nodejs-github-bot merged commit c750049 into nodejs:main Aug 31, 2023

Copy link
Copy Markdown
Collaborator

Landed in c750049

UlisesGascon pushed a commit that referenced this pull request Sep 10, 2023
PR-URL: #49397
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
UlisesGascon mentioned this pull request Sep 10, 2023
targos pushed a commit that referenced this pull request Nov 27, 2023
PR-URL: #49397
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
sercher added a commit to sercher/graaljs that referenced this pull request Apr 25, 2024
PR-URL: nodejs/node#49397
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
sercher added a commit to sercher/graaljs that referenced this pull request Apr 25, 2024
PR-URL: nodejs/node#49397
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
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

Labels

author ready PRs that have at least one approval, no outstanding review comments, and a CI started. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. experimental Issues and PRs related to experimental features. needs-ci PRs that need a full CI run. test_runner Issues and PRs related to the test runner subsystem.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants


Back | FazBrowse Home | New Git URL