UnitTest2.cs 434 B

123456789101112131415161718192021222324
  1. using Admin.NET.Application.Service;
  2. using Xunit;
  3. namespace Admin.NET.UnitTest;
  4. /// <summary>
  5. /// 单元测试
  6. /// </summary>
  7. public class UnitTest2
  8. {
  9. private readonly TestService _testService;
  10. public UnitTest2(TestService testService)
  11. {
  12. _testService = testService;
  13. }
  14. [Fact]
  15. public void 测试接口()
  16. {
  17. var res = _testService.GetName();
  18. Assert.Equal("Furion1", res);
  19. }
  20. }