From cfab6ad089bdb8735cd8f4f69c2acdd2990c3a32 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 26 Jun 2025 21:04:19 +0000 Subject: [PATCH 1/2] Update dependency AppCoreNet.Data.EntityFrameworkCore to 0.7.0 --- Directory.Packages.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Directory.Packages.props b/Directory.Packages.props index 7d68c18..109411b 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -35,7 +35,7 @@ - + From 49570f8020ec2e3469ac47c16baa218b02b928a2 Mon Sep 17 00:00:00 2001 From: Christian Prochnow Date: Fri, 27 Jun 2025 08:36:18 +0200 Subject: [PATCH 2/2] Fixed compiler errors. Added integration test run to workflow. --- .github/workflows/build-test.yaml | 27 +++++++++++++++++++ .../SqlServerEventStoreBuilderExtensions.cs | 16 +++++------ .../SqlServerEventStoreTests.cs | 2 +- .../SqlServerSubscriptionStoreTests.cs | 2 +- 4 files changed, 37 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build-test.yaml b/.github/workflows/build-test.yaml index c2207a7..22419cc 100644 --- a/.github/workflows/build-test.yaml +++ b/.github/workflows/build-test.yaml @@ -61,6 +61,33 @@ jobs: path: ./test-results if: ${{ always() }} # Always run this step even on failure + integration-tests: + runs-on: ubuntu-latest + needs: build + name: Integration Tests + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: Setup .NET + uses: actions/setup-dotnet@v4 + with: + dotnet-version: | + 8.0.x + 9.0.x + - name: Set BUILD_CONFIGURATION + if: startsWith(github.ref, 'refs/tags/') + run: echo "BUILD_CONFIGURATION=Release" >> $GITHUB_ENV + - name: Restore + run: dotnet restore + - name: Run Integration Tests + run: dotnet test --configuration ${{env.BUILD_CONFIGURATION}} --filter "Category=Integration" --logger trx --results-directory integration-test-results + - name: Upload integration test results + uses: actions/upload-artifact@v4 + with: + name: integration-test-results + path: ./integration-test-results + deploy-testing: if: github.event_name == 'push' runs-on: ubuntu-latest diff --git a/src/AppCoreNet.EventStore.SqlServer/DependencyInjection/SqlServerEventStoreBuilderExtensions.cs b/src/AppCoreNet.EventStore.SqlServer/DependencyInjection/SqlServerEventStoreBuilderExtensions.cs index 595c4b6..c32b61f 100644 --- a/src/AppCoreNet.EventStore.SqlServer/DependencyInjection/SqlServerEventStoreBuilderExtensions.cs +++ b/src/AppCoreNet.EventStore.SqlServer/DependencyInjection/SqlServerEventStoreBuilderExtensions.cs @@ -107,12 +107,12 @@ public static IEventStoreBuilder AddSqlServer( /// /// Registers the SQL server based event store for the data provider. /// - /// The . + /// The . /// Delegate used to configure the SQL server event store. /// The type of the . - /// The which allows chaining of method calls. - public static DbContextDataProviderBuilder AddSqlServerEventStore( - this DbContextDataProviderBuilder builder, + /// The which allows chaining of method calls. + public static EntityFrameworkCoreDataProviderBuilder AddSqlServerEventStore( + this EntityFrameworkCoreDataProviderBuilder builder, Action? configureOptions = null) where TDbContext : DbContext { @@ -125,12 +125,12 @@ public static DbContextDataProviderBuilder AddSqlServerEventStore /// Registers the SQL server based event store for the data provider. /// - /// The . + /// The . /// Delegate used to configure the SQL server event store. /// The type of the . - /// The which allows chaining of method calls. - public static DbContextDataProviderBuilder AddSqlServerEventStore( - this DbContextDataProviderBuilder builder, + /// The which allows chaining of method calls. + public static EntityFrameworkCoreDataProviderBuilder AddSqlServerEventStore( + this EntityFrameworkCoreDataProviderBuilder builder, Action configureOptions) where TDbContext : DbContext { diff --git a/test/AppCoreNet.EventStore.SqlServer.Tests/SqlServerEventStoreTests.cs b/test/AppCoreNet.EventStore.SqlServer.Tests/SqlServerEventStoreTests.cs index 4a2fd32..8eff70d 100644 --- a/test/AppCoreNet.EventStore.SqlServer.Tests/SqlServerEventStoreTests.cs +++ b/test/AppCoreNet.EventStore.SqlServer.Tests/SqlServerEventStoreTests.cs @@ -38,7 +38,7 @@ protected override void ConfigureServices(IServiceCollection services) services.AddDataProvider( p => { - p.AddDbContext( + p.AddEntityFrameworkCore( o => { o.UseSqlServer(_sqlServerTestFixture.ConnectionString); diff --git a/test/AppCoreNet.EventStore.SqlServer.Tests/Subscriptions/SqlServerSubscriptionStoreTests.cs b/test/AppCoreNet.EventStore.SqlServer.Tests/Subscriptions/SqlServerSubscriptionStoreTests.cs index 9a21c95..989ed21 100644 --- a/test/AppCoreNet.EventStore.SqlServer.Tests/Subscriptions/SqlServerSubscriptionStoreTests.cs +++ b/test/AppCoreNet.EventStore.SqlServer.Tests/Subscriptions/SqlServerSubscriptionStoreTests.cs @@ -34,7 +34,7 @@ protected override void ConfigureServices(IServiceCollection services) services.AddDataProvider( p => { - p.AddDbContext( + p.AddEntityFrameworkCore( o => { o.UseSqlServer(_sqlServerTestFixture.ConnectionString);