Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
shorten comment
  • Loading branch information
chris-olszewski committed Nov 9, 2026
commit 61cb88fbbda110b54be36e4256cd1f88ab60ee23
8 changes: 1 addition & 7 deletions packages/test/src/test-worker-owned-connection.local.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,8 @@
/**
* Verify that Workers close connections they create themselves, shutting down the Runtime without
* an explicit connection.close(). test-worker-lifecycle-integration.ts covers supplied connections,
* which callers must close after Worker shutdown, against both local servers and Cloud.
* These tests require the default local server because Worker.create() accepts connection settings
* only through a supplied connection.
*/
import { PromiseCompletionTimeoutError, Runtime } from '@temporalio/worker';
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.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

if (RUN_INTEGRATION_TESTS) {
test.serial('Worker closes its implicit connection and shuts down the Runtime', async (t) => {
const worker = await Worker.create({ ...defaultOptions, taskQueue: uniqueTaskQueue(t.title) });
Expand Down
Loading