You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
1.3 KiB

2 years ago
  1. using Shentun.Utilities;
  2. using System;
  3. using System.Collections.Generic;
  4. using System.Linq;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7. using Xunit.Abstractions;
  8. namespace Shentun.Peis.PlugIns.Tests
  9. {
  10. public class PacsImportResultPlugInsTest
  11. {
  12. private readonly ITestOutputHelper _output;
  13. public PacsImportResultPlugInsTest(ITestOutputHelper testOutputHelper)
  14. {
  15. _output = testOutputHelper;
  16. }
  17. [Fact]
  18. public async Task ImportResultAsync()
  19. {
  20. string configParm;
  21. string filePath = DirectoryHelper.GetAppDirectory() + "/appsettings.json";
  22. configParm = File.ReadAllText(filePath);
  23. var input = new ImportPacsResultPlugInsBase(configParm);
  24. var list = await input.GetRequestPatientRegisters(
  25. 30);
  26. foreach(var item in list )
  27. {
  28. _output.WriteLine(item.PatientRegisterId.ToString());
  29. }
  30. }
  31. [Fact]
  32. public async Task DoWorkAsync()
  33. {
  34. string configParm;
  35. string filePath = DirectoryHelper.GetAppDirectory() + "/appsettings.json";
  36. configParm = File.ReadAllText(filePath);
  37. var input = new ImportPacsResultPlugInsBase(configParm);
  38. await input.DoWork();
  39. }
  40. }
  41. }