Repository navigation
test(node): Support batched integration scenarios - #26493
nicohrubec wants to merge 1 commit into
Conversation
size-limit report 📦Compared: 73fe2e2 (PR test merge using develop at ef89ae2) Against: ef89ae2 (develop) · base run #67338 ✅ Baseline matches: this diff contains only this PR's changes.
|
9a01fea to
16e37e1
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 16e37e1. Configure here.
| await convertEsmFileToCjs(destination, destination.replace(/\.mjs$/, '.cjs')); | ||
| } | ||
| const imports = scenarios.map( | ||
| (scenario, index) => `import * as scenario${index} from './${basename(scenario)}';`, |
There was a problem hiding this comment.
Batched scenarios flatten to colliding names
Medium Severity
Batched scenario entries are read with join(cwd, scenario), so subdirectory paths work, but each file is copied and imported as basename(scenario). Two entries that share a filename (for example v5/scenario.mjs and v6/scenario.mjs) overwrite the same tmp file, and both generated imports load whichever copy was written last. The test.scenario attribute still records the original path, so later assertions can look correct while the wrong scenario ran.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 16e37e1. Configure here.
Co-Authored-By: OpenAI Codex <codex@openai.com>
16e37e1 to
97918c6
Compare


What
Allow compatible integration scenarios to share one Node process in ESM or CJS.
Why
Start the SDK once, then run each scenario with a fresh isolation scope so scenario-specific state stays separate. Exported scenarios can also run individually, allowing SDK versions to keep sharing their fixture files.
Used by OpenAI #26381, Vercel AI #26486, Anthropic/Mistral #26487, Google GenAI #26488, and LangChain/Mastra/pi-durable #26489. Each depends directly on this runner PR.