public async void ValidateCreate_Invalid_MasterIdentifier() { var service = new NrlsMaintain(_nrlsApiSettings, _fhirMaintain, _fhirSearch, _cache, _fhirValidation); var validation = await service.ValidateCreate <DocumentReference>(FhirRequests.Valid_Create_MasterId); Assert.IsType <OperationOutcome>(validation); }
public async void ValidateCreate_Valid() { var service = new NrlsMaintain(_nrlsApiSettings, _fhirMaintain, _fhirSearch, _cache, _fhirValidation); var validation = await service.ValidateCreate <DocumentReference>(FhirRequests.Valid_Create); Assert.Null(validation); }
public async void ValidateCreate_Invalid_Custodian() { var service = new NrlsMaintain(_nrlsApiSettings, _fhirMaintain, _fhirSearch, _sdsService, _fhirValidation); var validation = await service.ValidateCreate(FhirRequests.Invalid_Custodian); Assert.IsType <OperationOutcome>(validation); }
public void ValidateCreate_Invalid_Pointer() { var service = new NrlsMaintain(_nrlsApiSettings, _fhirMaintain, _fhirSearch, _cache, _fhirValidation); Assert.ThrowsAsync <HttpFhirException>(async delegate { await SystemTasks.Task.Run(async() => { var validation = await service.ValidateCreate <DocumentReference>(FhirRequests.Invalid_Create); }); }); }