-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feature: Update to Shiny 2.* +semver:minor * fixing net6 syntax
- Loading branch information
1 parent
d34dc7b
commit ebdc350
Showing
9 changed files
with
90 additions
and
61 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
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
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
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
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
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 FluentAssertions; | ||
using Microsoft.Extensions.Configuration; | ||
using Microsoft.Extensions.DependencyInjection; | ||
using NSubstitute; | ||
using Shiny; | ||
using Xunit; | ||
|
||
namespace Airframe.Tests.Shiny | ||
{ | ||
public class ReactiveShinyStartupTests | ||
{ | ||
[Fact] | ||
public void Should_Register_Configuration() | ||
{ | ||
// Given | ||
var configuration = Substitute.For<IConfiguration>(); | ||
var serviceCollection = new ServiceCollection(); | ||
var sut = new TestStartup(serviceCollection, configuration); | ||
|
||
// When | ||
sut.ConfigureServices(serviceCollection, Arg.Any<IPlatform>()); | ||
|
||
// Then | ||
serviceCollection.Should().ContainSingle(x => x.ServiceType == typeof(IConfiguration)); | ||
} | ||
|
||
} | ||
} |
6 changes: 3 additions & 3 deletions
6
test/Airframe.Tests/Shiny/Settings/SettingsProviderFixture.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
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
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,21 @@ | ||
using Microsoft.Extensions.Configuration; | ||
using Microsoft.Extensions.DependencyInjection; | ||
using Rocket.Surgery.Airframe.Shiny; | ||
|
||
namespace Airframe.Tests.Shiny | ||
{ | ||
internal class TestStartup : ReactiveShinyStartup | ||
{ | ||
/// <summary> | ||
/// Initializes a new instance of the <see cref="ReactiveShinyStartup"/> class. | ||
/// </summary> | ||
/// <param name="serviceCollection">The service collection.</param> | ||
/// <param name="configuration">The configuration.</param> | ||
public TestStartup(IServiceCollection serviceCollection, IConfiguration configuration) | ||
: base(serviceCollection, configuration) { } | ||
|
||
protected override void ConfigureServices(IServiceCollection services) { } | ||
|
||
protected override void ConfigureShiny(IServiceCollection services) { } | ||
} | ||
} |