Skip to content

Add Testcontainers integration testing sample#134

Open
bgener wants to merge 2 commits intotemporalio:mainfrom
bgener:feat/testcontainers
Open

Add Testcontainers integration testing sample#134
bgener wants to merge 2 commits intotemporalio:mainfrom
bgener:feat/testcontainers

Conversation

@bgener
Copy link
Copy Markdown

@bgener bgener commented Apr 15, 2026

What was changed

Adds a Testcontainers sample that shows how to integrate Temporal workflows against real PostgreSQL and Temporal containers.

Why?

Some workflows need external dependencies like databases to test properly. The built-in test server handles Temporal, but you still need to set up those dependencies yourself. Testcontainers lets the test fixture manage everything: Temporal, PostgreSQL, whatever else you need. It all starts before tests, tears down after, no manual setup.

Testcontainers for .NET recently added a Temporal module (shipped in release 4.11, PR testcontainers/testcontainers-dotnet#1635). I contributed those changes and am now adding this sample to show how to use it.

Checklist

  1. How was this tested: xUnit integration tests (happy path, failure with compensation, workflow query, etc.)
  2. Any docs updates needed? README update for the new sample

@bgener bgener requested a review from a team as a code owner April 15, 2026 16:36
@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Apr 15, 2026

CLA assistant check
All committers have signed the CLA.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants