diff options
| author | Patrick Barron <barronpm@gmail.com> | 2020-08-16 17:25:14 -0400 |
|---|---|---|
| committer | Patrick Barron <barronpm@gmail.com> | 2020-08-16 17:25:14 -0400 |
| commit | a77cf53573f95c5db27470bd0701c304f7a01c9e (patch) | |
| tree | fbfc02bca7ef4e264636a95b7350ee5de38c95dd /tests | |
| parent | 075ae53d831abdb4eb72aa7da575058a51d36753 (diff) | |
Allow plugins to register services.
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/MediaBrowser.Api.Tests/JellyfinApplicationFactory.cs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/MediaBrowser.Api.Tests/JellyfinApplicationFactory.cs b/tests/MediaBrowser.Api.Tests/JellyfinApplicationFactory.cs index c39ed07de..2029f88e9 100644 --- a/tests/MediaBrowser.Api.Tests/JellyfinApplicationFactory.cs +++ b/tests/MediaBrowser.Api.Tests/JellyfinApplicationFactory.cs @@ -72,6 +72,7 @@ namespace MediaBrowser.Api.Tests var startupConfig = Program.CreateAppConfiguration(commandLineOpts, appPaths); ILoggerFactory loggerFactory = new SerilogLoggerFactory(); + var serviceCollection = new ServiceCollection(); _disposableComponents.Add(loggerFactory); // Create the app host and initialize it @@ -80,10 +81,10 @@ namespace MediaBrowser.Api.Tests loggerFactory, commandLineOpts, new ManagedFileSystem(loggerFactory.CreateLogger<ManagedFileSystem>(), appPaths), - new NetworkManager(loggerFactory.CreateLogger<NetworkManager>())); + new NetworkManager(loggerFactory.CreateLogger<NetworkManager>()), + serviceCollection); _disposableComponents.Add(appHost); - var serviceCollection = new ServiceCollection(); - appHost.Init(serviceCollection); + appHost.Init(); // Configure the web host builder Program.ConfigureWebHostBuilder(builder, appHost, serviceCollection, commandLineOpts, startupConfig, appPaths); |
