GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — lib: added SuiteContext class · nodejs/node@55f800b

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • lib/internal/test_runner
    • test.js
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎lib/internal/test_runner/test.js‎

Copy file name to clipboardExpand all lines: lib/internal/test_runner/test.js
+18-1Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,22 @@ class TestContext {
146146
}
147147
}
148148

149+
class SuiteContext {
150+
#suite;
151+
152+
constructor(suite) {
153+
this.#suite = suite;
154+
}
155+
156+
get signal() {
157+
return this.#suite.signal;
158+
}
159+
160+
get name() {
161+
return this.#suite.name;
162+
}
163+
}
164+
149165
class Test extends AsyncResource {
150166
#abortController;
151167
#outerSignal;
@@ -737,7 +753,8 @@ class Suite extends Test {
737753
}
738754

739755
getRunArgs() {
740-
return { ctx: { signal: this.signal, name: this.name }, args: [] };
756+
const ctx = new SuiteContext(this);
757+
return { ctx, args: [ctx] };
741758
}
742759

743760
async run() {

0 commit comments

Comments
0 (0)
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.