File tree Expand file tree Collapse file tree 2 files changed +7
-1
lines changed
src/InformaticsGateway/Test Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change 16
16
17
17
using System . Threading . Tasks ;
18
18
using Microsoft . AspNetCore . Hosting ;
19
+ using Microsoft . Extensions . DependencyInjection ;
19
20
using Monai . Deploy . InformaticsGateway . Services . Http ;
21
+ using Monai . Deploy . Security . Authentication . Configurations ;
20
22
using Xunit ;
21
23
22
24
namespace Monai . Deploy . InformaticsGateway . Test . Services . Http
@@ -28,6 +30,10 @@ public async Task Startup_WebHostBuildsProperly()
28
30
{
29
31
var webHost = Microsoft . AspNetCore . WebHost . CreateDefaultBuilder ( )
30
32
. UseEnvironment ( "Development" )
33
+ . ConfigureServices ( ( hostContext , services ) =>
34
+ {
35
+ services . AddOptions < AuthenticationOptions > ( ) . Bind ( hostContext . Configuration . GetSection ( "MonaiDeployAuthentication" ) ) ;
36
+ } )
31
37
. UseStartup < Startup > ( )
32
38
. Build ( ) ;
33
39
Assert . NotNull ( webHost ) ;
Original file line number Diff line number Diff line change 1
1
{
2
2
"MonaiDeployAuthentication" : {
3
- "BypassAuthentication " : true
3
+ "bypassAuthentication " : true
4
4
},
5
5
"ConnectionStrings" : {
6
6
"Type" : " Sqlite" ,
You can’t perform that action at this time.
0 commit comments