test(node): Automatically run all node-integration tests with orchestrion#21911
Conversation
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 5f165ca. Configure here.
a146b15 to
4bb53a3
Compare
|
|
||
| return startInactiveSpan({ | ||
| name: sql ?? 'mysql.query', | ||
| kind: SPAN_KIND.CLIENT, |
There was a problem hiding this comment.
this is actually a regression that was found by this change!
| }, | ||
| withEnv: function (env: Record<string, string>) { | ||
| withEnv = env; | ||
| withEnv = { |
There was a problem hiding this comment.
change this to extend instead of overwrite this, aligning with how withFlags works.
| } | ||
|
|
||
| /** Returns true if orchestrion is enabled in env vars. */ | ||
| export function isOrchestrionEnabled(): boolean { |
There was a problem hiding this comment.
l: This can be removed, seems to be a duplicate from the utils/index.ts
There was a problem hiding this comment.
this is needed for usage in scenario usage where you need to do e.g. import { isOrchestrionEnabled } from '@sentry-internal/node-integration-tests' while the one in utils is for in-test usage. at least this is our current differentiation, not 100% sure if we need this 😅
PR #21911 makes createEsmAndCjsTests run every node integration test under orchestrion automatically (INJECT_ORCHESTRION), so the manual OTel/orchestrion variant matrix is no longer needed. Collapse the apollo-graphql suite back to a single variant per scenario and branch only the span origin on isOrchestrionEnabled(); drop the redundant instrument-orchestrion.mjs (the runner injects experimentalUseDiagnosticsChannelInjection). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Rely on `createEsmAndCjsTests` auto-running the suite with orchestrion on CI (#21911) instead of a manual instrument matrix: drop `instrument-orchestrion.mjs` and branch the expected span origin on `isOrchestrionEnabled()`. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
develop now runs all node-integration tests a second time with INJECT_ORCHESTRION (#21911). Under orchestrion, ioredis <5.11 is instrumented by the diagnostics-channel subscriber, so its span origin is 'auto.db.orchestrion.redis' instead of the OTel monkey-patch's 'auto.db.otel.redis'. Branch the expected ioredis origin on isOrchestrionEnabled(); node-redis (redis-4/redis-5) is not ported and keeps the OTel origin. All other span attributes are identical. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
PR #21911 auto-runs all createEsmAndCjsTests under orchestrion, so the dedicated openai/orchestrion suite is redundant. Deletes it and makes the proxy tests orchestrion-aware: - Drops the explicit `openAIIntegration()` from the no-option instrument files so orchestrion replaces the default integration under injection (proxy path is unaffected — it's a default). - Branches the span-origin assertions on `isOrchestrionEnabled()` (`auto.ai.orchestrion.openai` vs `auto.ai.openai`). - Keeps proxy-origin assertions for cases that can't run orchestrion: the mock/manual openai-tool-calls suite, and the truncation blocks whose `enableTruncation: true` must stay on the explicit integration (it overrides the streamGenAiSpans auto-disable). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Rely on `createEsmAndCjsTests` auto-running the suite with orchestrion on CI (#21911) instead of a manual instrument matrix: drop `instrument-orchestrion.mjs` and branch the expected span origin on `isOrchestrionEnabled()`. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Rely on `createEsmAndCjsTests` auto-running the suite with orchestrion on CI (#21911) instead of a manual instrument matrix: drop `instrument-orchestrion.mjs` and branch the expected span origin on `isOrchestrionEnabled()`. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Rely on `createEsmAndCjsTests` auto-running the suite with orchestrion on CI (#21911) instead of a manual instrument matrix: drop `instrument-orchestrion.mjs` and branch the expected span origin on `isOrchestrionEnabled()`. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

Instead of manually building test matrixes for this, this runs node 20 and node 26 integration tests created via
createEsmAndCjsTestswith orchestrion automatically on CI.I choose to keep the custom matrix for mysql as a placeholder, so we can test the different ways to run orchestrion there manually. but IMHO other, following instrumentation can simply skip this and rely on the auto running.
For differences in runs you can use the
isOrchestrionEnabled()helper both in runtime code as well as in test code.