From 90b567e1e29dbf1db7584f9648ea7079316bc086 Mon Sep 17 00:00:00 2001 From: Neil South Date: Thu, 7 Sep 2023 10:01:22 +0100 Subject: [PATCH] fixing builds Signed-off-by: Neil South --- src/InformaticsGateway/Repositories/MonaiServiceLocator.cs | 4 ++-- .../Test/Services/DicomWeb/StowServiceTest.cs | 5 +++++ .../Test/Services/Http/DicomWeb/StowControllerTest.cs | 3 +++ 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/InformaticsGateway/Repositories/MonaiServiceLocator.cs b/src/InformaticsGateway/Repositories/MonaiServiceLocator.cs index b0f68674f..d5a00e8e5 100755 --- a/src/InformaticsGateway/Repositories/MonaiServiceLocator.cs +++ b/src/InformaticsGateway/Repositories/MonaiServiceLocator.cs @@ -47,12 +47,12 @@ public Dictionary GetServiceStatus() return _runningServices.ToDictionary(k => k.ServiceName, v => v.Status); } - private IMonaiService GetService(Type type) + private IMonaiService? GetService(Type type) { Guard.Against.Null(type, nameof(type)); return - (_serviceProvider.GetService(type) as IMonaiService)!; + (_serviceProvider.GetService(type) as IMonaiService); } diff --git a/src/InformaticsGateway/Test/Services/DicomWeb/StowServiceTest.cs b/src/InformaticsGateway/Test/Services/DicomWeb/StowServiceTest.cs index c8004e11f..5b512a001 100755 --- a/src/InformaticsGateway/Test/Services/DicomWeb/StowServiceTest.cs +++ b/src/InformaticsGateway/Test/Services/DicomWeb/StowServiceTest.cs @@ -14,10 +14,15 @@ * limitations under the License. */ +using System; +using System.Collections.Generic; +using System.IO; using System.IO.Abstractions; using System.IO.Abstractions.TestingHelpers; using System.Net; using System.Text; +using System.Threading; +using System.Threading.Tasks; using FellowOakDicom; using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Mvc.ModelBinding; diff --git a/src/InformaticsGateway/Test/Services/Http/DicomWeb/StowControllerTest.cs b/src/InformaticsGateway/Test/Services/Http/DicomWeb/StowControllerTest.cs index 62ddfdce2..02a60a6de 100755 --- a/src/InformaticsGateway/Test/Services/Http/DicomWeb/StowControllerTest.cs +++ b/src/InformaticsGateway/Test/Services/Http/DicomWeb/StowControllerTest.cs @@ -25,6 +25,9 @@ using Monai.Deploy.InformaticsGateway.Services.Storage; using Moq; using Xunit; +using System.Threading.Tasks; +using System; +using System.Threading; namespace Monai.Deploy.InformaticsGateway.Test.Services.Http.DicomWeb {