Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,14 @@ internal sealed class MosquittoFixture : IAsyncDisposable
public MosquittoFixture()
{
var conf = "listener 1883\nallow_anonymous true\n";
_container = new ContainerBuilder()
.WithImage("eclipse-mosquitto:2")
// Testcontainers 4.10+ requires an explicit image at builder construction
// (parameterless ctor + chained .WithImage(...) is obsolete and slated for removal).
// The wait strategy renamed UntilPortIsAvailable → UntilExternalTcpPortIsAvailable
// in 4.7.0 and the old name was removed in a later patch; semantics still apply.
_container = new ContainerBuilder("eclipse-mosquitto:2")
.WithPortBinding(1883, true)
.WithResourceMapping(Encoding.UTF8.GetBytes(conf), "/mosquitto/config/mosquitto.conf")
.WithWaitStrategy(Wait.ForUnixContainer().UntilPortIsAvailable(1883))
.WithWaitStrategy(Wait.ForUnixContainer().UntilExternalTcpPortIsAvailable(1883))
.Build();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
<PackageReference Include="Testcontainers" Version="4.4.0" />
<PackageReference Include="Testcontainers" Version="4.11.0" />
<PackageReference Include="WireMock.Net" Version="2.4.0" />
<PackageReference Include="MQTTnet" Version="5.1.0.1559" />
<!-- OpenTelemetry in-memory exporter — test-only, never in src/. Per PLAN-3.1 Task 3. -->
Expand Down