diff --git a/TransactionProcessor.IntegrationTests/Common/DockerHelper.cs b/TransactionProcessor.IntegrationTests/Common/DockerHelper.cs index ad04589f..345666f3 100644 --- a/TransactionProcessor.IntegrationTests/Common/DockerHelper.cs +++ b/TransactionProcessor.IntegrationTests/Common/DockerHelper.cs @@ -377,10 +377,13 @@ private async Task RemoveEstateReadModel() { String databaseName = $"EstateReportingReadModel{estateId}"; - // Build the connection string (to master) - String connectionString = Setup.GetLocalConnectionString(databaseName); - EstateReportingContext context = new EstateReportingContext(connectionString); - await context.Database.EnsureDeletedAsync(CancellationToken.None); + await Retry.For(async () => + { + // Build the connection string (to master) + String connectionString = Setup.GetLocalConnectionString(databaseName); + EstateReportingContext context = new EstateReportingContext(connectionString); + await context.Database.EnsureDeletedAsync(CancellationToken.None); + }); } }