aboutsummaryrefslogtreecommitdiff
path: root/Timeline.Tests/Mock/Services/TestClock.cs
diff options
context:
space:
mode:
author杨宇千 <crupest@outlook.com>2019-10-17 20:46:57 +0800
committer杨宇千 <crupest@outlook.com>2019-10-17 20:46:57 +0800
commitdef8e8dd78812c019a0d6e8e5a3e2de4e82ae3e4 (patch)
treedc7688d7d2dd5ab28a7e3c553154ee84676f75d2 /Timeline.Tests/Mock/Services/TestClock.cs
parent297d0c9029360f1d5334ed843b9b299356740ec1 (diff)
downloadtimeline-def8e8dd78812c019a0d6e8e5a3e2de4e82ae3e4.tar.gz
timeline-def8e8dd78812c019a0d6e8e5a3e2de4e82ae3e4.tar.bz2
timeline-def8e8dd78812c019a0d6e8e5a3e2de4e82ae3e4.zip
...
Diffstat (limited to 'Timeline.Tests/Mock/Services/TestClock.cs')
-rw-r--r--Timeline.Tests/Mock/Services/TestClock.cs10
1 files changed, 0 insertions, 10 deletions
diff --git a/Timeline.Tests/Mock/Services/TestClock.cs b/Timeline.Tests/Mock/Services/TestClock.cs
index 0082171e..6671395a 100644
--- a/Timeline.Tests/Mock/Services/TestClock.cs
+++ b/Timeline.Tests/Mock/Services/TestClock.cs
@@ -1,5 +1,3 @@
-using Microsoft.AspNetCore.Mvc.Testing;
-using Microsoft.Extensions.DependencyInjection;
using System;
using Timeline.Services;
@@ -14,12 +12,4 @@ namespace Timeline.Tests.Mock.Services
return MockCurrentTime.GetValueOrDefault(DateTime.Now);
}
}
-
- public static class TestClockWebApplicationFactoryExtensions
- {
- public static TestClock GetTestClock<T>(this WebApplicationFactory<T> factory) where T : class
- {
- return factory.Server.Host.Services.GetRequiredService<IClock>() as TestClock;
- }
- }
}