public void Errors_Should_Return_Null_If_Ok() { var qpcr = new QueryPreflightCheckResult { QueryRef = new QueryRef(QueryUrn.From("urn:leaf:query:d7359679-df0d-4604-a2d9-1d3d04417dc2:123456")), IsPresent = true, IsAuthorized = true, ConceptCheck = new ConceptPreflightCheck { Results = new ConceptPreflightCheckResult[] { new ConceptPreflightCheckResult { Id = Guid.NewGuid(), UniversalId = ConceptUrn.From("urn:leaf:concept:diag:codeset=ICD9+code=123.42"), IsPresent = true, IsAuthorized = true }, new ConceptPreflightCheckResult { Id = Guid.NewGuid(), UniversalId = ConceptUrn.From("urn:leaf:concept:diag:codeset=ICD9+code=123.45"), IsPresent = true, IsAuthorized = true } } } }; Assert.Null(qpcr.Errors()); }
public QueryPreflightCheckResultDTO(QueryPreflightCheckResult result) { Id = result.QueryRef?.Id; UniversalId = result.QueryRef?.UniversalId?.ToString(); Ver = result.Ver; IsPresent = result.IsPresent; IsAuthorized = result.IsAuthorized; ConceptPreflight = new ConceptPreflightCheckDTO(result.ConceptCheck); }
public void Ok_Theory(QueryPreflightCheckResult result, bool expected) { var ok = result.Ok; Assert.Equal(expected, ok); }