Repository navigation
Conversation
Use Worker-owned connections built from envconfig instead of the shared test environment, whose connections keep the Runtime alive, so the tests again assert that the Runtime shuts down when the last Worker stops. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ests Tests that assert Runtime teardown need each Worker to own its connection, so the Runtime shuts down once the last Worker stops; a shared test environment keeps it alive. Move that helper into helpers.ts, choosing the server like createTestWorkflowEnvironment() does (envconfig only when TEMPORAL_TEST_ENV_CONFIG_SERVER is set, otherwise TEMPORAL_SERVICE_ADDRESS or the default local address) instead of always reading a local envconfig profile. Also give lifecycle tests unique task queues, since a namespace may be shared. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Runtime integration tests connected implicitly to localhost and the default namespace. Use Workers that own configured connections (through the shared helper) and clients on the same configured server, so the Runtime still shuts down and restarts as the tests expect. Replace the fixed `q1`/`q2` task queues with unique ones. Renamed to test-runtime-integration.ts, since test-runtime.ts already exists. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
chris-olszewski
force-pushed
the
codex/cloud-adapt-runtime-lifecycle
branch
from
November 9, 2026 17:09
41814a1 to
51b996a
Compare
| import { RUN_INTEGRATION_TESTS, test, uniqueTaskQueue, Worker } from './helpers'; | ||
| import { defaultOptions } from './mock-native-worker'; | ||
|
|
||
| // These tests are local only as there is no way to provide options to the Worker created connection. |
Member
There was a problem hiding this comment.
These are both taken from packages/test/src/test-worker-lifecycle-integration.ts where we can't specify the Worker owned connection to target cloud without depending on internals. I don't think it is worth creating a new internal entrypoint to allow configuring the connection created by Worker.create. Might be worth adding the ability to specify connection options for the Worker owned connection if we really feel we should have cloud coverage here.
chris-olszewski
marked this pull request as ready for review
November 9, 2026 18:27
This branch has not been deployed
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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What was changed
test-runtime.cloud-pending.ts→test-runtime-integration.ts) now use the configured server and namespace instead of an implicit localhost connection. Fixedq1/q2task queues are now unique.The helper picks the server the same way the test environment does: envconfig when
TEMPORAL_TEST_ENV_CONFIG_SERVERis set (Cloud), otherwiseTEMPORAL_SERVICE_ADDRESSor the default local address.Why?
Part of moving the integration tests to run on Temporal Cloud, without weakening the Runtime lifecycle checks.
Checklist
Both files pass locally against a CLI dev server, three runs in a row (9/9 each).
No.
🤖 Generated with Claude Code