Skip to content

Commit 8b06847

Browse files
authored
Fix parallel integration test execution for all frameworks (#8)
1 parent c1e198f commit 8b06847

File tree

4 files changed

+30
-10
lines changed

4 files changed

+30
-10
lines changed

.github/workflows/build-test.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,12 @@ jobs:
2121
uses: actions/checkout@v4
2222

2323
- name: .NET - setup
24-
uses: actions/setup-dotnet@v3
24+
uses: actions/setup-dotnet@v5
2525
with:
26-
dotnet-version: '8.x'
26+
dotnet-version: |
27+
8.0.x
28+
9.0.x
29+
10.0.x
2730
2831
- name: .NET - restore & Build
2932
run: dotnet build

docker/startup.sql

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
11
CREATE database aspnetidentity;
22
CREATE USER aspnetidentity WITH PASSWORD 'aspnetidentity';
3-
ALTER USER aspnetidentity WITH SUPERUSER;
3+
ALTER USER aspnetidentity WITH SUPERUSER;
4+
5+
CREATE DATABASE aspnetidentity_net8;
6+
CREATE USER aspnetidentity_net8 WITH PASSWORD 'aspnetidentity';
7+
ALTER USER aspnetidentity_net8 WITH SUPERUSER;
8+
9+
CREATE DATABASE aspnetidentity_net9;
10+
CREATE USER aspnetidentity_net9 WITH PASSWORD 'aspnetidentity';
11+
ALTER USER aspnetidentity_net9 WITH SUPERUSER;
12+
13+
CREATE DATABASE aspnetidentity_net10;
14+
CREATE USER aspnetidentity_net10 WITH PASSWORD 'aspnetidentity';
15+
ALTER USER aspnetidentity_net10 WITH SUPERUSER;

global.json

Lines changed: 0 additions & 6 deletions
This file was deleted.

src/Marten.AspNetIdentity.Tests/Integration/DocumentStoreManager.cs

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,18 @@ namespace Marten.AspNetIdentity.Tests.Integration
66
public class DocumentStoreManager
77
{
88
private static readonly ConcurrentDictionary<string, IDocumentStore> _documentStores = new ConcurrentDictionary<string, IDocumentStore>();
9-
public static string ConnectionString => "host=localhost;port=5432;database=aspnetidentity;username=aspnetidentity;password=aspnetidentity;";
9+
public static string ConnectionString => $"host=localhost;port=5432;database={DbName};username=aspnetidentity;password=aspnetidentity;";
10+
11+
private static string DbName =>
12+
#if NET10_0
13+
"aspnetidentity_net10";
14+
#elif NET9_0
15+
"aspnetidentity_net9";
16+
#elif NET8_0
17+
"aspnetidentity_net8";
18+
#else
19+
"aspnetidentity";
20+
#endif
1021

1122
public static IDocumentStore GetMartenDocumentStore(Type testClassType, string connectionString = null)
1223
{

0 commit comments

Comments
 (0)