Skip to content

Test Bun compatibility in CI - #1433

Open
cristianrgreco wants to merge 9 commits into
mainfrom
codex/test-bun-compatibility
Open

Test Bun compatibility in CI#1433
cristianrgreco wants to merge 9 commits into
mainfrom
codex/test-bun-compatibility

Conversation

@cristianrgreco

@cristianrgreco cristianrgreco commented Aug 9, 2026

Copy link
Copy Markdown
Collaborator

Summary

Verification

  • initial Bun 1.3.14 matrix: 35 workspace jobs passed and exposed the linked runtime incompatibilities
  • retained Bun K3s and OpenSearch tests: 3 tests passed
  • Bun HTTP wait strategy and Docker log stream checks after merging main: 16 tests passed
  • CI_BUN=true test discovery confirmed only the linked incompatible tests are omitted
  • Node.js test discovery confirmed the existing tests remain enabled
  • workflow YAML parsing passed
  • npm run format
  • npm run lint

Compatibility

This is non-breaking: it changes CI coverage and test selection only; published package code and public APIs are unchanged.

@netlify

netlify Bot commented Aug 9, 2026

Copy link
Copy Markdown

Deploy Preview for testcontainers-node ready!

Name Link
🔨 Latest commit fc4d6c3
🔍 Latest deploy log https://app.netlify.com/projects/testcontainers-node/deploys/6a78dfac1fa6e600089120a8
😎 Deploy Preview https://deploy-preview-1433--testcontainers-node.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@cristianrgreco cristianrgreco added maintenance Improvements that do not change functionality patch Backward compatible bug fix labels Aug 9, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6c22505457

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 156 to 158
strategy:
fail-fast: false
max-parallel: 20
matrix:

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Cap the split test matrices

On repository-wide changes, package detection selects all 43 workspaces, so these three independent matrices can collectively start up to 215 runner jobs (86 Docker, 86 Podman, and 43 Bun), whereas the previous combined matrix was limited by max-parallel: 20. Restore an aggregate concurrency cap so this workflow cannot monopolize the organization’s runner capacity.

Useful? React with 👍 / 👎.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0e431ee2f7

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +8 to +9
// https://github.com/oven-sh/bun/issues/19337
if (process.env.BUN_CI) return;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Keep the Bun-safe Redpanda HTTP tests enabled

When BUN_CI is set, this return also removes the schema-registry, admin, and REST-proxy tests, even though those tests only use fetch and never load the incompatible Kafka client; the new dynamic import in test-helper.ts already isolates that client. Guard only the message-production test so the Bun matrix still verifies these observable Redpanda behaviors.

AGENTS.md reference: AGENTS.md:L29-L30

Useful? React with 👍 / 👎.

Comment on lines +10 to +11
// https://github.com/oven-sh/bun/issues/19337
if (process.env.BUN_CI) return;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Run Kafka tests that do not use the native client

In the Bun job, this suite-wide return also skips the reuse check, Docker-network Kafka CLI check, and unsupported-version validation tests, none of which call assertMessageProducedAndConsumed or load the incompatible native client. Limit the guard to tests that invoke that helper so Bun continues exercising the compatible container behavior.

AGENTS.md reference: AGENTS.md:L29-L30

Useful? React with 👍 / 👎.

Comment on lines +11 to +12
// https://github.com/oven-sh/bun/issues/19337
if (process.env.BUN_CI) return;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Preserve the Bun-safe Kafka latest checks

When BUN_CI is set, this return suppresses the reuse test and the SASL-in-network test that uses the containerized Kafka CLI; neither path imports the incompatible native Kafka client. Guard only the tests that call assertMessageProducedAndConsumed so these observable behaviors remain covered under Bun.

AGENTS.md reference: AGENTS.md:L29-L30

Useful? React with 👍 / 👎.

Comment on lines 25 to +28
describe("MongoDBAtlasLocalContainer", { timeout: 240_000 }, () => {
// Static loading uses node:v8 APIs unsupported by Bun before this suite can return.
// https://github.com/oven-sh/bun/issues/32501
if (process.env.BUN_CI) return;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Retain MongoDB Atlas tests that do not import Mongoose

In the Bun matrix, this return skips the three connection-string tests before the first dynamic mongoose import, even though the linked node:v8 incompatibility cannot affect those paths. Guard only the Mongoose-dependent tests so Bun still verifies the container's connection-string behavior.

AGENTS.md reference: AGENTS.md:L29-L30

Useful? React with 👍 / 👎.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d3cbeefad0

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".


describe("CouchbaseContainer", { timeout: 180_000 }, () => {
// https://github.com/oven-sh/bun/issues/12730
if (process.env.BUN_CI) return;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Keep Bun-safe Couchbase tests enabled

When BUN_CI is set, this suite-wide return also removes the community-edition service validation, analytics startup, and fixed-host-port tests, none of which invoke the incompatible couchbase.Cluster client path. Guard only the client-dependent tests so Bun continues verifying these observable container behaviors.

AGENTS.md reference: AGENTS.md:L29-L30

Useful? React with 👍 / 👎.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1e78a8b801

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

test:
name: "Run"
runs-on: ${{ inputs.runner }}
timeout-minutes: 20

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Scope the 20-minute timeout to Bun jobs

This reusable template serves the Docker and Podman matrices as well as Bun, so the new limit also shortens every existing Node job. In a slow run, packages/modules/chromadb/src/chromadb-container.test.ts permits 360 seconds per attempt while vitest.config.ts enables three CI retries, meaning a test can legitimately need up to 24 minutes before setup time; the job can therefore be cancelled during a retry that would otherwise pass. Apply the short timeout only to Bun, where it guards the documented hang, or raise the shared timeout enough to preserve the existing retry budget.

Useful? React with 👍 / 👎.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: fc4d6c3e9a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

describe.sequential("Reaper", { timeout: 120_000 }, () => {
// The Bun core job disables Ryuk because its open stream prevents the process from exiting.
// https://github.com/oven-sh/bun/issues/23776
if (process.env.BUN_CI) return;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Keep the disabled-Ryuk test enabled for Bun

When the Bun core job sets TESTCONTAINERS_RYUK_DISABLED=true, this suite-wide return also skips the test that verifies the disabled reaper can accept sessions and projects without starting Ryuk—the exact behavior on which that job relies to avoid hanging. Skip only the tests that require a live Ryuk socket so Bun continues validating its configured cleanup mode.

AGENTS.md reference: AGENTS.md:L29-L30

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Improvements that do not change functionality patch Backward compatible bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant