-
-
Notifications
You must be signed in to change notification settings - Fork 235
Closed
Labels
Description
Describe the bug
Custom WireMock images that include their own mappings like from the guide can not be used in WireMockContainerBuilder.WithImage() leading to a InvalidOperationException on Build() because _imageOS is never set.
Expected behavior:
var container = new WireMockContainerBuilder()
.WithLinuxImage()
.WithImage("custom-wiremock:latest")
.WithAutoRemove(true)
.WithCleanUp(true)
.Build();
await container.StartAsync().ConfigureAwait(false);
var client = container.CreateClient();
// Start requesting the built-in mappingsI expect with the above code to work an not throw an exception. However after WithLinuxImage() _imageOS is still set to null because the builder objects gets recreated from scratch with only the docker config remaining.
Reactions are currently unavailable