Added test for APIs

This commit is contained in:
Daniel Wathen
2023-01-17 15:51:47 -07:00
parent a0c3e66dc1
commit b428464a02
8 changed files with 128 additions and 18 deletions

View File

@ -19,7 +19,6 @@ public class AppSettings
[Display(Name = "MonA Resource"), Required] public string MonAResource { get; set; }
[Display(Name = "MonA Site"), Required] public string MonASite { get; set; }
[Display(Name = "Tool State Owner File Path"), Required] public string ToolStateOwnerFilePath { get; set; }
[Display(Name = "URLs"), Required] public string URLs { get; set; }
#nullable enable
@ -54,8 +53,6 @@ public class AppSettings
throw new NullReferenceException(nameof(MonAResource));
if (appSettings.MonASite is null)
throw new NullReferenceException(nameof(MonASite));
if (appSettings.URLs is null)
throw new NullReferenceException(nameof(URLs));
if (appSettings.ToolStateOwnerFilePath is null)
throw new NullReferenceException(nameof(ToolStateOwnerFilePath));
result = new(
@ -69,8 +66,7 @@ public class AppSettings
appSettings.IsStaging.Value,
appSettings.MonAResource,
appSettings.MonASite,
appSettings.ToolStateOwnerFilePath,
appSettings.URLs);
appSettings.ToolStateOwnerFilePath);
return result;
}