Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
</PropertyGroup>
<ItemGroup>
<PackageVersion Include="Alba" Version="8.4.1" />
<PackageVersion Include="Alba" Version="8.5.2" />
<PackageVersion Include="AWSSDK.SimpleNotificationService" Version="4.0.2.14" />
<PackageVersion Include="AWSSDK.SQS" Version="4.0.2.14" />
<PackageVersion Include="Azure.Identity" Version="1.17.0" />
Expand Down Expand Up @@ -33,7 +33,7 @@
<PackageVersion Include="MemoryPack" Version="1.21.3" />
<PackageVersion Include="MessagePack" Version="3.1.3" />
<PackageVersion Include="Meziantou.Extensions.Logging.Xunit" Version="1.0.15" />
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Testing" Version="9.0.6" />
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Testing" Version="9.0.14" />
<PackageVersion Include="Microsoft.AspNetCore.SignalR" Version="1.1.0" />
<PackageVersion Include="Microsoft.AspNetCore.SignalR.Client" Version="9.0.8" />
<PackageVersion Include="Microsoft.Azure.SignalR" Version="1.32.0" />
Expand Down
3 changes: 0 additions & 3 deletions src/Http/Wolverine.Http.Tests/Bugs/Bug_using_host_stop.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using Alba;
using JasperFx.CommandLine;
using JasperFx.Core.Reflection;
using Microsoft.AspNetCore.Builder;
using Microsoft.Extensions.Hosting;
Expand Down Expand Up @@ -77,8 +76,6 @@ await CreateAlbaHostWithWithFactory()

private static async Task<IHost> CreateAlbaHostWithWithFactory()
{
JasperFxEnvironment.AutoStartHost = true; // to start the underlying host

return await AlbaHost.For<WolverineWebApi.Program>(x =>
x.ConfigureServices(ConfigureWolverine));
}
Expand Down
6 changes: 0 additions & 6 deletions src/Http/Wolverine.Http.Tests/IntegrationContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
using Microsoft.AspNetCore.Routing;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.OpenApi.Models;
using JasperFx.CommandLine;
using Shouldly;
using Swashbuckle.AspNetCore.Swagger;
using Wolverine.Tracking;
Expand All @@ -19,11 +18,6 @@ public class AppFixture : IAsyncLifetime

public async Task InitializeAsync()
{
// Sorry folks, but this is absolutely necessary if you
// use JasperFx for command line processing and want to
// use WebApplicationFactory and/or Alba for integration testing
JasperFxEnvironment.AutoStartHost = true;

// For "integration" test collection (based on this fixture) ApplicationAssembly is WolverineWebApi.
// If not set explicitly here other tests may set it to the test assembly causing issues with endpoints discovery.
JasperFxOptions.RememberedApplicationAssembly = typeof(WolverineWebApi.Program).Assembly;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
using Alba;
using IntegrationTests;
using JasperFx.CommandLine;
using Marten.Exceptions;
using Microsoft.Data.SqlClient;
using Microsoft.EntityFrameworkCore;
Expand All @@ -10,8 +9,6 @@
using SharedPersistenceModels.Items;
using SharedPersistenceModels.Orders;
using Shouldly;
using Weasel.Postgresql;
using Weasel.SqlServer;
using Wolverine;
using Wolverine.EntityFrameworkCore;
using Wolverine.EntityFrameworkCore.Internals;
Expand All @@ -38,7 +35,6 @@ public abstract class MultiTenancyCompliance : IAsyncLifetime, IWolverineExtensi

protected MultiTenancyCompliance(DatabaseEngine engine)
{
JasperFxEnvironment.AutoStartHost = true;
TestingOverrides.Extension = this;

_engine = engine;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using Alba;
using JasperFx;
using JasperFx.CommandLine;
using Microsoft.Extensions.DependencyInjection;
using Polecat;
using Wolverine;
Expand All @@ -17,8 +15,6 @@ public class AppFixture : IAsyncLifetime

public async Task InitializeAsync()
{
JasperFxEnvironment.AutoStartHost = true;

Host = await AlbaHost.For<Program>(x =>
{
x.ConfigureServices(services =>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
using Alba;
using Marten;
using Microsoft.Extensions.DependencyInjection;
using JasperFx;
using JasperFx.CommandLine;
using Wolverine.Runtime;

namespace DiagnosticsTests;
Expand All @@ -13,11 +11,8 @@ public class AppFixture : IAsyncLifetime

public async Task InitializeAsync()
{
JasperFxEnvironment.AutoStartHost = true;

// This is bootstrapping the actual application using
// its implied Program.Main() set up

Host = await AlbaHost.For<Program>(x => { });
}

Expand Down
7 changes: 0 additions & 7 deletions src/Samples/EFCoreSample/ItemService.Tests/end_to_end.cs
Original file line number Diff line number Diff line change
@@ -1,20 +1,13 @@
using Alba;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.DependencyInjection;
using JasperFx;
using JasperFx.CommandLine;
using Shouldly;
using Wolverine.Tracking;

namespace ItemService.Tests;

public class end_to_end
{
public end_to_end()
{
JasperFxEnvironment.AutoStartHost = true;
}

[Fact]
public async Task run_through_the_handler()
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,13 @@
using Alba;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.DependencyInjection;
using JasperFx;
using JasperFx.CommandLine;
using Shouldly;
using Wolverine.Tracking;

namespace ItemService.Tests;

public class end_to_end_for_dbcontext_not_integrated_with_outbox
{
public end_to_end_for_dbcontext_not_integrated_with_outbox()
{
JasperFxEnvironment.AutoStartHost = true;
}

[Fact]
public async Task run_through_the_handler()
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
using Alba;
using Alba.Security;
using Marten;
using Microsoft.Extensions.DependencyInjection;
using JasperFx;
using JasperFx.CommandLine;
using Wolverine;
using Wolverine.Runtime;
using Wolverine.Tracking;
Expand All @@ -20,8 +17,6 @@ public class AppFixture : IAsyncLifetime

public async Task InitializeAsync()
{
JasperFxEnvironment.AutoStartHost = true;

// This is bootstrapping the actual application using
// its implied Program.Main() set up
Host = await AlbaHost.For<Program>(x =>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
using Marten;
using Microsoft.Extensions.DependencyInjection;
using NSubstitute;
using JasperFx;
using JasperFx.CommandLine;
using Shouldly;
using Wolverine;
using Xunit.Abstractions;
Expand All @@ -17,9 +15,6 @@ public class try_out_the_middleware

public try_out_the_middleware(ITestOutputHelper output)
{
// Boo! I blame the AspNetCore team for this one though
JasperFxEnvironment.AutoStartHost = true;

_output = output;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
using Marten;
using Microsoft.Extensions.DependencyInjection;
using Npgsql;
using JasperFx;
using JasperFx.CommandLine;
using Shouldly;
using Weasel.Postgresql;
using Weasel.Postgresql.Migrations;
Expand Down Expand Up @@ -35,10 +33,6 @@ public async Task InitializeAsync()
await createDatabaseIfNotExists(conn, "tenant2");
await createDatabaseIfNotExists(conn, "tenant3");

// Sorry folks, this is a hidden trap
// I blame the AspNetCore team...
JasperFxEnvironment.AutoStartHost = true;

var securityStub = new JwtSecurityStub()
.With("claim", "value");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
using JasperFx.Core;
using JasperFx.Core.Reflection;
using Microsoft.Extensions.DependencyInjection;
using JasperFx;
using JasperFx.CommandLine;
using Shouldly;
using Wolverine.Tracking;

Expand All @@ -16,7 +14,6 @@ public class AlbaTestHarness
[Fact]
public async Task run_end_to_end_with_stub_services()
{
JasperFxEnvironment.AutoStartHost = true;
using var host = await AlbaHost.For<Program>(builder =>
{
builder.ConfigureServices(services => services.AddSingleton<IAccountService, StubAccountService>());
Expand Down
6 changes: 0 additions & 6 deletions src/Samples/TodoWebService/TodoWebServiceTests/end_to_end.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
using Marten;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.DependencyInjection;
using JasperFx;
using JasperFx.CommandLine;
using Shouldly;
using TodoWebService;
using Wolverine.Tracking;
Expand All @@ -16,10 +14,6 @@ public class end_to_end : IAsyncLifetime

public async Task InitializeAsync()
{
// Sorry folks, this is a hidden trap
// I blame the AspNetCore team...
JasperFxEnvironment.AutoStartHost = true;

_host = await AlbaHost.For<Program>();

// Wiping out any leftover data in the database
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using Alba;
using JasperFx;
using JasperFx.CommandLine;
using JasperFx.Core;
using Shouldly;
using Wolverine.Tracking;
Expand All @@ -13,8 +11,6 @@ public class batch_processing_with_kafka
[Fact]
public async Task end_to_end()
{
JasperFxEnvironment.AutoStartHost = true;

await using var host = await AlbaHost.For<Program>(_ => {});

IScenarioResult result = null!;
Expand Down
Loading