aboutsummaryrefslogtreecommitdiff
path: root/BackEnd/Timeline.Tests/Helpers/TestApplication.cs
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2021-05-15 16:01:21 +0800
committercrupest <crupest@outlook.com>2021-05-15 16:01:21 +0800
commite9017498a0bd87e2a5ae457c00f9ddee35809c29 (patch)
tree3658ceb6200f0feaf1d2a95d5d9990aba9de9fbd /BackEnd/Timeline.Tests/Helpers/TestApplication.cs
parentd5c70793f203dccf96219b89c2da8e5432617e17 (diff)
downloadtimeline-e9017498a0bd87e2a5ae457c00f9ddee35809c29.tar.gz
timeline-e9017498a0bd87e2a5ae457c00f9ddee35809c29.tar.bz2
timeline-e9017498a0bd87e2a5ae457c00f9ddee35809c29.zip
feat: Timeline post change notification with signalr.
Diffstat (limited to 'BackEnd/Timeline.Tests/Helpers/TestApplication.cs')
-rw-r--r--BackEnd/Timeline.Tests/Helpers/TestApplication.cs7
1 files changed, 7 insertions, 0 deletions
diff --git a/BackEnd/Timeline.Tests/Helpers/TestApplication.cs b/BackEnd/Timeline.Tests/Helpers/TestApplication.cs
index e0db966c..723ef500 100644
--- a/BackEnd/Timeline.Tests/Helpers/TestApplication.cs
+++ b/BackEnd/Timeline.Tests/Helpers/TestApplication.cs
@@ -1,6 +1,8 @@
using Microsoft.AspNetCore.Hosting;
+using Microsoft.AspNetCore.Hosting.Server;
using Microsoft.AspNetCore.TestHost;
using Microsoft.Extensions.Configuration;
+using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using System.Collections.Generic;
using System.IO;
@@ -46,5 +48,10 @@ namespace Timeline.Tests.Helpers
Directory.Delete(WorkDirectory, true);
}
+
+ public TestServer Server
+ {
+ get => (TestServer)Host.Services.GetRequiredService<IServer>();
+ }
}
}