Skip to content

Commit 609ad64

Browse files
authored
Merge branch 'develop' into feature/allow-cancel-start-of-fixture
2 parents d83c04f + d053837 commit 609ad64

31 files changed

Lines changed: 591 additions & 28 deletions

.cake-scripts/version.cake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#addin nuget:?package=Cake.Git&version=4.0.0
1+
#addin nuget:?package=Cake.Git&version=5.0.1
22

33
internal sealed class BuildInformation
44
{

.config/dotnet-tools.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"isRoot": true,
44
"tools": {
55
"cake.tool": {
6-
"version": "4.2.0",
6+
"version": "5.0.0",
77
"commands": [
88
"dotnet-cake"
99
]

.github/workflows/cicd.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ jobs:
6464
{ name: "Testcontainers.Keycloak", runs-on: "ubuntu-22.04" },
6565
{ name: "Testcontainers.Kusto", runs-on: "ubuntu-22.04" },
6666
{ name: "Testcontainers.LocalStack", runs-on: "ubuntu-22.04" },
67+
{ name: "Testcontainers.LowkeyVault", runs-on: "ubuntu-22.04" },
6768
{ name: "Testcontainers.MariaDb", runs-on: "ubuntu-22.04" },
6869
{ name: "Testcontainers.Milvus", runs-on: "ubuntu-22.04" },
6970
{ name: "Testcontainers.Minio", runs-on: "ubuntu-22.04" },
@@ -90,7 +91,8 @@ jobs:
9091
{ name: "Testcontainers.Sftp", runs-on: "ubuntu-22.04" },
9192
{ name: "Testcontainers.Weaviate", runs-on: "ubuntu-22.04" },
9293
{ name: "Testcontainers.WebDriver", runs-on: "ubuntu-22.04" },
93-
{ name: "Testcontainers.Xunit", runs-on: "ubuntu-22.04" }
94+
{ name: "Testcontainers.Xunit", runs-on: "ubuntu-22.04" },
95+
{ name: "Testcontainers.XunitV3", runs-on: "ubuntu-22.04" }
9496
]
9597

9698
runs-on: ${{ matrix.test-projects.runs-on }}

Directory.Packages.props

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
<PackageVersion Include="xunit.analyzers" Version="1.21.0"/>
2222
<PackageVersion Include="xunit.runner.visualstudio" Version="3.0.2"/>
2323
<PackageVersion Include="xunit" Version="2.9.3"/>
24+
<PackageVersion Include="xunit.v3" Version="2.0.1"/>
2425
<!-- xUnit.net extensibility for Testcontainers.Xunit and Testcontainers.XunitV3 packages: -->
2526
<PackageVersion Include="xunit.extensibility.execution" Version="2.9.3"/>
2627
<PackageVersion Include="xunit.v3.extensibility.core" Version="1.1.0"/>
@@ -76,5 +77,8 @@
7677
<PackageVersion Include="RavenDB.Client" Version="5.4.100"/>
7778
<PackageVersion Include="Selenium.WebDriver" Version="4.8.1"/>
7879
<PackageVersion Include="StackExchange.Redis" Version="2.6.90"/>
80+
<PackageVersion Include="Azure.Identity" Version="1.13.2" />
81+
<PackageVersion Include="Azure.Security.KeyVault.Certificates" Version="4.7.0" />
82+
<PackageVersion Include="Azure.Security.KeyVault.Secrets" Version="4.7.0" />
7983
</ItemGroup>
8084
</Project>

Testcontainers.sln

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.Kusto", "src
6969
EndProject
7070
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.LocalStack", "src\Testcontainers.LocalStack\Testcontainers.LocalStack.csproj", "{3792268A-EF08-4569-8118-991E08FD61C4}"
7171
EndProject
72+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.LowkeyVault", "src\Testcontainers.LowkeyVault\Testcontainers.LowkeyVault.csproj", "{436486CE-E855-43DA-A2C7-9832E98BD86E}"
73+
EndProject
7274
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.MariaDb", "src\Testcontainers.MariaDb\Testcontainers.MariaDb.csproj", "{4B204EB3-C478-422E-9B6F-62DF3871291A}"
7375
EndProject
7476
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.Milvus", "src\Testcontainers.Milvus\Testcontainers.Milvus.csproj", "{B024E315-831F-429D-92AA-44B839AC10F4}"
@@ -177,6 +179,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.Kusto.Tests"
177179
EndProject
178180
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.LocalStack.Tests", "tests\Testcontainers.LocalStack.Tests\Testcontainers.LocalStack.Tests.csproj", "{728CBE16-1D52-4F84-AF01-7229E6013512}"
179181
EndProject
182+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.LowkeyVault.Tests", "tests\Testcontainers.LowkeyVault.Tests\Testcontainers.LowkeyVault.Tests.csproj", "{CB4F241B-EB79-49D5-A45F-050BEE2191B8}"
183+
EndProject
180184
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.MariaDb.Tests", "tests\Testcontainers.MariaDb.Tests\Testcontainers.MariaDb.Tests.csproj", "{7F0AE083-9DB8-4BD4-91F7-C199DCC7301D}"
181185
EndProject
182186
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.Milvus.Tests", "tests\Testcontainers.Milvus.Tests\Testcontainers.Milvus.Tests.csproj", "{5247DF94-32F3-4ED6-AE71-6AB4F4078E6D}"
@@ -239,14 +243,13 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.WebDriver.Te
239243
EndProject
240244
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.Xunit.Tests", "tests\Testcontainers.Xunit.Tests\Testcontainers.Xunit.Tests.csproj", "{E901DF14-6F05-4FC2-825A-3055FAD33561}"
241245
EndProject
246+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Testcontainers.XunitV3.Tests", "tests\Testcontainers.XunitV3.Tests\Testcontainers.XunitV3.Tests.csproj", "{B2E8B7FB-7D1E-4DD3-A25E-34DE4386B1EB}"
247+
EndProject
242248
Global
243249
GlobalSection(SolutionConfigurationPlatforms) = preSolution
244250
Debug|Any CPU = Debug|Any CPU
245251
Release|Any CPU = Release|Any CPU
246252
EndGlobalSection
247-
GlobalSection(SolutionProperties) = preSolution
248-
HideSolutionNode = FALSE
249-
EndGlobalSection
250253
GlobalSection(ProjectConfigurationPlatforms) = postSolution
251254
{5365F780-0E6C-41F0-B1B9-7DC34368F80C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
252255
{5365F780-0E6C-41F0-B1B9-7DC34368F80C}.Debug|Any CPU.Build.0 = Debug|Any CPU
@@ -448,6 +451,10 @@ Global
448451
{64A87DE5-29B0-4A54-9E74-560484D8C7C0}.Debug|Any CPU.Build.0 = Debug|Any CPU
449452
{64A87DE5-29B0-4A54-9E74-560484D8C7C0}.Release|Any CPU.ActiveCfg = Release|Any CPU
450453
{64A87DE5-29B0-4A54-9E74-560484D8C7C0}.Release|Any CPU.Build.0 = Release|Any CPU
454+
{436486CE-E855-43DA-A2C7-9832E98BD86E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
455+
{436486CE-E855-43DA-A2C7-9832E98BD86E}.Debug|Any CPU.Build.0 = Debug|Any CPU
456+
{436486CE-E855-43DA-A2C7-9832E98BD86E}.Release|Any CPU.ActiveCfg = Release|Any CPU
457+
{436486CE-E855-43DA-A2C7-9832E98BD86E}.Release|Any CPU.Build.0 = Release|Any CPU
451458
{380BB29B-F556-404D-B13B-CA250599C565}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
452459
{380BB29B-F556-404D-B13B-CA250599C565}.Debug|Any CPU.Build.0 = Debug|Any CPU
453460
{380BB29B-F556-404D-B13B-CA250599C565}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -696,10 +703,21 @@ Global
696703
{EBA72C3B-57D5-43FF-A5B4-3D55B3B6D4C2}.Debug|Any CPU.Build.0 = Debug|Any CPU
697704
{EBA72C3B-57D5-43FF-A5B4-3D55B3B6D4C2}.Release|Any CPU.ActiveCfg = Release|Any CPU
698705
{EBA72C3B-57D5-43FF-A5B4-3D55B3B6D4C2}.Release|Any CPU.Build.0 = Release|Any CPU
706+
{CB4F241B-EB79-49D5-A45F-050BEE2191B8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
707+
{CB4F241B-EB79-49D5-A45F-050BEE2191B8}.Debug|Any CPU.Build.0 = Debug|Any CPU
708+
{CB4F241B-EB79-49D5-A45F-050BEE2191B8}.Release|Any CPU.ActiveCfg = Release|Any CPU
709+
{CB4F241B-EB79-49D5-A45F-050BEE2191B8}.Release|Any CPU.Build.0 = Release|Any CPU
699710
{E901DF14-6F05-4FC2-825A-3055FAD33561}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
700711
{E901DF14-6F05-4FC2-825A-3055FAD33561}.Debug|Any CPU.Build.0 = Debug|Any CPU
701712
{E901DF14-6F05-4FC2-825A-3055FAD33561}.Release|Any CPU.ActiveCfg = Release|Any CPU
702713
{E901DF14-6F05-4FC2-825A-3055FAD33561}.Release|Any CPU.Build.0 = Release|Any CPU
714+
{B2E8B7FB-7D1E-4DD3-A25E-34DE4386B1EB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
715+
{B2E8B7FB-7D1E-4DD3-A25E-34DE4386B1EB}.Debug|Any CPU.Build.0 = Debug|Any CPU
716+
{B2E8B7FB-7D1E-4DD3-A25E-34DE4386B1EB}.Release|Any CPU.ActiveCfg = Release|Any CPU
717+
{B2E8B7FB-7D1E-4DD3-A25E-34DE4386B1EB}.Release|Any CPU.Build.0 = Release|Any CPU
718+
EndGlobalSection
719+
GlobalSection(SolutionProperties) = preSolution
720+
HideSolutionNode = FALSE
703721
EndGlobalSection
704722
GlobalSection(NestedProjects) = preSolution
705723
{5365F780-0E6C-41F0-B1B9-7DC34368F80C} = {673F23AE-7694-4BB9-ABD4-136D6C13634E}
@@ -752,6 +770,7 @@ Global
752770
{7D5C6816-0DD2-4E13-A585-033B5D3C80D5} = {673F23AE-7694-4BB9-ABD4-136D6C13634E}
753771
{68F8600D-24E9-4E03-9E25-5F6EB338EAC1} = {673F23AE-7694-4BB9-ABD4-136D6C13634E}
754772
{64A87DE5-29B0-4A54-9E74-560484D8C7C0} = {673F23AE-7694-4BB9-ABD4-136D6C13634E}
773+
{436486CE-E855-43DA-A2C7-9832E98BD86E} = {673F23AE-7694-4BB9-ABD4-136D6C13634E}
755774
{380BB29B-F556-404D-B13B-CA250599C565} = {673F23AE-7694-4BB9-ABD4-136D6C13634E}
756775
{84911C93-C2A9-46E9-AE5E-D567306589E5} = {673F23AE-7694-4BB9-ABD4-136D6C13634E}
757776
{EC76857B-A3B8-4B7A-A1B0-8D867A4D1733} = {673F23AE-7694-4BB9-ABD4-136D6C13634E}
@@ -814,6 +833,8 @@ Global
814833
{27CDB869-A150-4593-958F-6F26E5391E7C} = {7164F1FB-7F24-444A-ACD2-2C329C2B3CCF}
815834
{DDB41BC8-5826-4D97-9C5F-001151E3FFD6} = {7164F1FB-7F24-444A-ACD2-2C329C2B3CCF}
816835
{EBA72C3B-57D5-43FF-A5B4-3D55B3B6D4C2} = {7164F1FB-7F24-444A-ACD2-2C329C2B3CCF}
836+
{CB4F241B-EB79-49D5-A45F-050BEE2191B8} = {7164F1FB-7F24-444A-ACD2-2C329C2B3CCF}
817837
{E901DF14-6F05-4FC2-825A-3055FAD33561} = {7164F1FB-7F24-444A-ACD2-2C329C2B3CCF}
838+
{B2E8B7FB-7D1E-4DD3-A25E-34DE4386B1EB} = {7164F1FB-7F24-444A-ACD2-2C329C2B3CCF}
818839
EndGlobalSection
819840
EndGlobal

build.cake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
#tool nuget:?package=dotnet-sonarscanner&version=9.0.1
1+
#tool nuget:?package=dotnet-sonarscanner&version=10.1.2
22

3-
#addin nuget:?package=Cake.Sonar&version=1.1.33
3+
#addin nuget:?package=Cake.Sonar&version=5.0.0
44

5-
#addin nuget:?package=Cake.Git&version=4.0.0
5+
#addin nuget:?package=Cake.Git&version=5.0.1
66

77
#load ".cake-scripts/parameters.cake"
88

docs/modules/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ await moduleNameContainer.StartAsync();
4949
| Keycloak | `quay.io/keycloak/keycloak:21.1` | [NuGet](https://www.nuget.org/packages/Testcontainers.Keycloak) | [Source](https://github.com/testcontainers/testcontainers-dotnet/tree/develop/src/Testcontainers.Keycloak) |
5050
| Kusto emulator | `mcr.microsoft.com/azuredataexplorer/kustainer-linux:latest` | [NuGet](https://www.nuget.org/packages/Testcontainers.Kusto) | [Source](https://github.com/testcontainers/testcontainers-dotnet/tree/develop/src/Testcontainers.Kusto) |
5151
| LocalStack | `localstack/localstack:2.0` | [NuGet](https://www.nuget.org/packages/Testcontainers.LocalStack) | [Source](https://github.com/testcontainers/testcontainers-dotnet/tree/develop/src/Testcontainers.LocalStack) |
52+
| Lowkey Vault | `nagyesta/lowkey-vault:2.7.1-ubi9-minimal` | [NuGet](https://www.nuget.org/packages/Testcontainers.LowkeyVault) | [Source](https://github.com/testcontainers/testcontainers-dotnet/tree/develop/src/Testcontainers.LowkeyVault) |
5253
| MariaDB | `mariadb:10.10` | [NuGet](https://www.nuget.org/packages/Testcontainers.MariaDb) | [Source](https://github.com/testcontainers/testcontainers-dotnet/tree/develop/src/Testcontainers.MariaDb) |
5354
| Milvus | `milvusdb/milvus:v2.3.10` | [NuGet](https://www.nuget.org/packages/Testcontainers.Milvus) | [Source](https://github.com/testcontainers/testcontainers-dotnet/tree/develop/src/Testcontainers.Milvus) |
5455
| MinIO | `minio/minio:RELEASE.2023-01-31T02-24-19Z` | [NuGet](https://www.nuget.org/packages/Testcontainers.Minio) | [Source](https://github.com/testcontainers/testcontainers-dotnet/tree/develop/src/Testcontainers.Minio) |

global.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"sdk": {
3-
"version": "9.0.100",
3+
"version": "9.0.200",
44
"rollForward": "latestMinor"
55
}
66
}

src/Testcontainers.EventHubs/EventHubsServiceConfiguration.cs

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,16 @@ private EventHubsServiceConfiguration(NamespaceConfig namespaceConfig)
5858

5959
public static EventHubsServiceConfiguration Create()
6060
{
61-
var namespaceConfig = new NamespaceConfig("EventHub", "ns-1", Array.Empty<Entity>());
61+
var namespaceConfig = new NamespaceConfig("EventHub", "emulatorns1", Array.Empty<Entity>());
6262
return new EventHubsServiceConfiguration(namespaceConfig);
6363
}
6464

6565
public EventHubsServiceConfiguration WithEntity(string name, int partitionCount, params string[] consumerGroupNames)
6666
{
67-
return WithEntity(name, partitionCount, new ReadOnlyCollection<string>(consumerGroupNames));
67+
// Filter out the consumer group name `$default` because the `$default` group
68+
// is created automatically by the container image.
69+
var validConsumerGroupNames = consumerGroupNames.Where(consumerGroupName => !"$Default".Equals(consumerGroupName, StringComparison.OrdinalIgnoreCase)).ToList();
70+
return WithEntity(name, partitionCount, new ReadOnlyCollection<string>(validConsumerGroupNames));
6871
}
6972

7073
public EventHubsServiceConfiguration WithEntity(string name, int partitionCount, IEnumerable<string> consumerGroupNames)
@@ -77,8 +80,10 @@ public EventHubsServiceConfiguration WithEntity(string name, int partitionCount,
7780

7881
public bool Validate()
7982
{
80-
Predicate<Entity> isValidEntity = entity => entity.PartitionCount > 0 && entity.PartitionCount <= 32 && entity.ConsumerGroups.Count > 0 && entity.ConsumerGroups.Count <= 20;
81-
return _namespaceConfig.Entities.All(entity => isValidEntity(entity));
83+
// The emulator provides the usage quotas as described at:
84+
// https://learn.microsoft.com/en-us/azure/event-hubs/overview-emulator#usage-quotas.
85+
Predicate<Entity> isValidEntity = entity => entity.PartitionCount > 0 && entity.PartitionCount <= 32 && entity.ConsumerGroups.Count <= 20;
86+
return _namespaceConfig.Entities.Count > 0 && _namespaceConfig.Entities.Count <= 10 && _namespaceConfig.Entities.All(entity => isValidEntity(entity));
8287
}
8388

8489
public string Build()
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
root = true

0 commit comments

Comments
 (0)