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

test_runner: Fix mock timer promisified setInterval return value by mika-fischer · Pull Request #50331 · nodejs/node · GitHub

/ node Public

test_runner: Fix mock timer promisified setInterval return value - #50331

Merged
nodejs-github-bot merged 3 commits into
nodejs:mainfrom
mika-fischer:fix-50307
Oct 25, 2023
Merged

test_runner: Fix mock timer promisified setInterval return value#50331
nodejs-github-bot merged 3 commits into
nodejs:mainfrom
mika-fischer:fix-50307

Conversation

Copy link
Copy Markdown
Contributor

promisified setInterval can be passed a value that is returned by the async iterable. The mocked promisified setInterval used this value for its own purposes. This brings the mocked version in line with the original.

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 Oct 22, 2023
atlowChemi added request-ci Add this label to start a Jenkins CI on a PR. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. author ready PRs that have at least one approval, no outstanding review comments, and a CI started. labels Oct 23, 2023
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Oct 23, 2023

Copy link
Copy Markdown
Collaborator

mika-fischer force-pushed the fix-50307 branch 2 times, most recently from 02d7e2e to e65beea Compare October 23, 2023 08:41
MoLow added the request-ci Add this label to start a Jenkins CI on a PR. label Oct 23, 2023
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Oct 23, 2023

Copy link
Copy Markdown
Collaborator

ErickWendel left a comment
edited
Loading

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM. @mika-fischer congrats on your first PR on the nodejs repo!! It's really helpful!

MoLow commented Oct 23, 2023

Copy link
Copy Markdown
Member

@mika-fischer the PR needs a rebase

promisified setInterval can be passed a value that is returned by the
async iterable. The mocked promisified setInterval used this value for
its own purposes. This brings the mocked version in line with the
original.

Fixes: nodejs#50307
Some tests relied on the custom return value and were broken by the
change to always return the value provided by the caller.

Copy link
Copy Markdown
Contributor Author

LGTM. @mika-fischer congrats on your first PR on the nodejs repo!! It's really helpful!

Thanks @ErickWendel!

Copy link
Copy Markdown
Contributor Author

@mika-fischer the PR needs a rebase

done @MoLow

MoLow added the request-ci Add this label to start a Jenkins CI on a PR. label Oct 23, 2023
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Oct 23, 2023

Copy link
Copy Markdown
Collaborator

Copy link
Copy Markdown
Contributor Author

I'm not sure why some tests are failing, these seem unrelated to the changes in this PR. Let me know if there's anything I can do to move this along.

Copy link
Copy Markdown
Collaborator

MoLow added the commit-queue Add this label to land a pull request using GitHub Actions. label Oct 23, 2023
nodejs-github-bot added commit-queue-failed An error occurred while landing this pull request using GitHub Actions. and removed commit-queue Add this label to land a pull request using GitHub Actions. labels Oct 24, 2023

Copy link
Copy Markdown
Collaborator
Commit Queue failed
- Loading data for nodejs/node/pull/50331
✔  Done loading data for nodejs/node/pull/50331
----------------------------------- PR info ------------------------------------
Title      test_runner: Fix mock timer promisified setInterval return value (#50331)
Author     Mika Fischer  (@mika-fischer, first-time contributor)
Branch     mika-fischer:fix-50307 -> nodejs:main
Labels     author ready, needs-ci, commit-queue-squash, test_runner
Commits    3
 - test_runner: test return value of mocked promisified timers
 - test_runner: fix mock timer promisified setInterval return value
 - test_runner: fix mock timer setInterval tests
Committers 1
 - Mika Fischer 
PR-URL: https://github.com/nodejs/node/pull/50331
Reviewed-By: Moshe Atlow 
Reviewed-By: Chemi Atlow 
Reviewed-By: Erick Wendel 
------------------------------ Generated metadata ------------------------------
PR-URL: https://github.com/nodejs/node/pull/50331
Reviewed-By: Moshe Atlow 
Reviewed-By: Chemi Atlow 
Reviewed-By: Erick Wendel 
--------------------------------------------------------------------------------
   ⚠  Commits were pushed since the last approving review:
   ⚠  - test_runner: test return value of mocked promisified timers
   ⚠  - test_runner: fix mock timer promisified setInterval return value
   ⚠  - test_runner: fix mock timer setInterval tests
   ℹ  This PR was created on Sun, 22 Oct 2023 20:11:55 GMT
   ✔  Approvals: 3
   ✔  - Moshe Atlow (@MoLow) (TSC): https://github.com/nodejs/node/pull/50331#pullrequestreview-1692229637
   ✔  - Chemi Atlow (@atlowChemi): https://github.com/nodejs/node/pull/50331#pullrequestreview-1691892475
   ✔  - Erick Wendel (@erickwendel): https://github.com/nodejs/node/pull/50331#pullrequestreview-1692276984
   ✔  Last GitHub CI successful
   ℹ  Last Full PR CI on 2023-10-23T18:44:37Z: https://ci.nodejs.org/job/node-test-pull-request/55158/
- Querying data for job/node-test-pull-request/55158/
   ✔  Last Jenkins CI successful
--------------------------------------------------------------------------------
   ✔  Aborted `git node land` session in /home/runner/work/node/node/.ncu
https://github.com/nodejs/node/actions/runs/6632107907

MoLow added commit-queue Add this label to land a pull request using GitHub Actions. and removed commit-queue-failed An error occurred while landing this pull request using GitHub Actions. labels Oct 25, 2023
nodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label Oct 25, 2023
nodejs-github-bot merged commit 4f5db8b into nodejs:main Oct 25, 2023

Copy link
Copy Markdown
Collaborator

Landed in 4f5db8b

mika-fischer deleted the fix-50307 branch October 25, 2023 07:29

Copy link
Copy Markdown
Contributor Author

Did the closure of #50307 get dropped somehow? Should I have specified it differently? Should I close the issue now manually?

Copy link
Copy Markdown
Member

Typically it needs Fixes: or Closes: in the PR description for GH to pick it up.

Thank you for your contribution!

targos pushed a commit that referenced this pull request Nov 11, 2023
PR-URL: #50331
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: Erick Wendel <erick.workspace@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
UlisesGascon pushed a commit that referenced this pull request Dec 11, 2023
PR-URL: #50331
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: Erick Wendel <erick.workspace@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
UlisesGascon mentioned this pull request Dec 12, 2023
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. 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.

node test mock timer promisified setTimeout & setInterval don't always return the specified value

6 participants


Back | FazBrowse Home | New Git URL