-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added integration test for MassTransit adapter package (#5)
- Loading branch information
Showing
2 changed files
with
48 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
...Extensions.Adapters.MassTransit/NybusLegacyServiceCollectionExtensionsIntegrationTests.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
using AutoFixture.NUnit3; | ||
using Microsoft.Extensions.Configuration; | ||
using Microsoft.Extensions.DependencyInjection; | ||
using NUnit.Framework; | ||
using Nybus; | ||
|
||
namespace Tests | ||
{ | ||
[TestFixture] | ||
public class NybusLegacyServiceCollectionExtensionsIntegrationTests | ||
{ | ||
[Test, AutoMoqData] | ||
public void Bus_can_be_built([Frozen] string connectionStringName, IConfiguration configuration, ServiceCollection services, NybusLegacyConfiguration nybusConfiguration) | ||
{ | ||
services.AddSingleton(configuration); | ||
|
||
services.AddLogging(); | ||
|
||
services.AddNybusWithMassTransit(nybusConfiguration); | ||
|
||
var serviceProvider = services.BuildServiceProvider(); | ||
|
||
var bus = serviceProvider.GetRequiredService<IBus>(); | ||
|
||
Assert.That(bus, Is.Not.Null); | ||
} | ||
} | ||
} |