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.
53 lines
1.8 KiB
53 lines
1.8 KiB
using Shentun.Peis.PlugIns.LisRequests;
|
|
using Shentun.Utilities;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using Xunit.Abstractions;
|
|
|
|
namespace Shentun.Peis.PlugIns.Tests
|
|
{
|
|
public class LisRequestPlugInsTest
|
|
{
|
|
private readonly ITestOutputHelper _output;
|
|
public LisRequestPlugInsTest(ITestOutputHelper testOutputHelper)
|
|
{
|
|
_output = testOutputHelper;
|
|
|
|
}
|
|
[Fact]
|
|
public async Task GetPatientRegisterForPlugInsAsync()
|
|
{
|
|
string configParm;
|
|
string filePath = DirectoryHelper.GetAppDirectory() + "/appsettings.json";
|
|
configParm = File.ReadAllText(filePath);
|
|
|
|
var lisRequestPlugInsBase = new LisRequestPlugInsBase(configParm);
|
|
var item = await lisRequestPlugInsBase.GetPatientRegisterForPlugInsAsync(
|
|
new Guid("3a123266-4581-83c4-9099-1f24cd0f3a49"));
|
|
_output.WriteLine(item.PatientNo + item.PatientName);
|
|
|
|
}
|
|
|
|
[Fact]
|
|
public async Task GetLisRequestForPlugInsAsync()
|
|
{
|
|
string configParm;
|
|
string filePath = DirectoryHelper.GetAppDirectory() + "/appsettings.json";
|
|
configParm = File.ReadAllText(filePath);
|
|
|
|
var lisRequestPlugInsBase = new LisRequestPlugInsBase(configParm);
|
|
var item = await lisRequestPlugInsBase.GetLisRequestForPlugInsAsync(
|
|
new Guid("3a123266-4581-83c4-9099-1f24cd0f3a49"));
|
|
_output.WriteLine(item.LisRequestNo + item.SampleContainerName);
|
|
foreach(var asbitem in item.Asbitems)
|
|
{
|
|
_output.WriteLine(asbitem.AsbitemId.ToString() + asbitem.AsbitemName);
|
|
}
|
|
}
|
|
|
|
|
|
}
|
|
}
|