Skip to content

test_runner: add tags and workerId to SuiteContext - #67312

Merged
nodejs-github-bot merged 3 commits into
nodejs:mainfrom
sangwook-dev:feat/test-runner-suite-context-tags-workerid
Nov 16, 2026
Merged

nodejs-github-bot merged 3 commits into
nodejs:mainfrom
sangwook-dev:feat/test-runner-suite-context-tags-workerid

Conversation

@sangwook-dev

@sangwook-dev sangwook-dev commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

TestContext exposes tags and workerId, but SuiteContext doesn't, so a
describe() callback can't read the suite's tags, including inherited ones.

This adds both to SuiteContext, like #62504 did for passed, attempt and
diagnostic().

Disclosure: I used a coding agent to help investigate and draft this change. I confirmed the missing properties on a main build, reviewed the change, and verified that the new tests fail without it.

TestContext exposes tags and workerId, but SuiteContext does not, so a
describe() callback cannot read the suite's tags, including the ones
inherited from ancestor suites. Expose both on SuiteContext as well.

Signed-off-by: sangwook <rewq5991@gmail.com>
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/test_runner

@nodejs-github-bot 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 Nov 7, 2026
@codecov

codecov Bot commented Nov 7, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 88.88889% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 90.72%. Comparing base (a43bfb5) to head (6679c91).
⚠️ Report is 121 commits behind head on main.

Files with missing lines Patch % Lines
lib/internal/test_runner/test.js 88.88% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #67312      +/-   ##
==========================================
- Coverage   93.00%   90.72%   -2.29%     
==========================================
  Files         428      798     +370     
  Lines      195818   280026   +84208     
  Branches    30283    53858   +23575     
==========================================
+ Hits       182117   254044   +71927     
- Misses      13375    16282    +2907     
- Partials      326     9700    +9374     
Files with missing lines Coverage Δ
lib/internal/test_runner/test.js 97.95% <88.88%> (+<0.01%) ⬆️

... and 521 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Signed-off-by: sangwook <rewq5991@gmail.com>
Signed-off-by: sangwook <rewq5991@gmail.com>
@atlowChemi atlowChemi added request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. commit-queue-squash PRs the Commit Queue should land as one squashed commit. labels Nov 10, 2026
@github-actions github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. label Nov 10, 2026
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

@sangwook-dev

Copy link
Copy Markdown
Contributor Author

@atlowChemi Could you retry the CI?

@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

@MoLow MoLow added author ready PRs with CI started, the required approvals, and no outstanding review comments. commit-queue PRs queued for automated landing through the Commit Queue. labels Nov 16, 2026
@nodejs-github-bot
nodejs-github-bot merged commit c48b26c into nodejs:main Nov 16, 2026
72 checks passed
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Landed in c48b26c

@nodejs-github-bot nodejs-github-bot removed the commit-queue PRs queued for automated landing through the Commit Queue. label Nov 16, 2026
@sangwook-dev
sangwook-dev deleted the feat/test-runner-suite-context-tags-workerid branch November 16, 2026 10:17
aduh95 pushed a commit that referenced this pull request Nov 19, 2026
TestContext exposes tags and workerId, but SuiteContext does not, so a
describe() callback cannot read the suite's tags, including the ones
inherited from ancestor suites. Expose both on SuiteContext as well.

Signed-off-by: sangwook <rewq5991@gmail.com>
PR-URL: #67312
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author ready PRs with CI started, the required approvals, and no outstanding review comments. commit-queue-squash PRs the Commit Queue should land as one squashed commit. 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.

5 participants