Removed unused HapiWorkerContext
This commit is contained in:
parent
e7e039a851
commit
16a4004f02
|
@ -7,10 +7,6 @@ import ca.uhn.fhir.validation.FhirValidator;
|
||||||
import ca.uhn.fhir.validation.ResultSeverityEnum;
|
import ca.uhn.fhir.validation.ResultSeverityEnum;
|
||||||
import ca.uhn.fhir.validation.SingleValidationMessage;
|
import ca.uhn.fhir.validation.SingleValidationMessage;
|
||||||
import ca.uhn.fhir.validation.ValidationResult;
|
import ca.uhn.fhir.validation.ValidationResult;
|
||||||
import org.apache.commons.io.IOUtils;
|
|
||||||
import org.hamcrest.Matchers;
|
|
||||||
import org.hl7.fhir.dstu3.context.IWorkerContext;
|
|
||||||
import org.hl7.fhir.dstu3.hapi.ctx.HapiWorkerContext;
|
|
||||||
import org.hl7.fhir.dstu3.hapi.ctx.IValidationSupport;
|
import org.hl7.fhir.dstu3.hapi.ctx.IValidationSupport;
|
||||||
import org.hl7.fhir.dstu3.hapi.ctx.IValidationSupport.CodeValidationResult;
|
import org.hl7.fhir.dstu3.hapi.ctx.IValidationSupport.CodeValidationResult;
|
||||||
import org.hl7.fhir.dstu3.model.*;
|
import org.hl7.fhir.dstu3.model.*;
|
||||||
|
@ -24,14 +20,12 @@ import org.hl7.fhir.dstu3.model.QuestionnaireResponse.QuestionnaireResponseItemC
|
||||||
import org.hl7.fhir.dstu3.model.QuestionnaireResponse.QuestionnaireResponseStatus;
|
import org.hl7.fhir.dstu3.model.QuestionnaireResponse.QuestionnaireResponseStatus;
|
||||||
import org.junit.AfterClass;
|
import org.junit.AfterClass;
|
||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.BeforeClass;
|
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.stream.Collectors;
|
|
||||||
|
|
||||||
import static org.hamcrest.Matchers.containsString;
|
import static org.hamcrest.Matchers.containsString;
|
||||||
import static org.hamcrest.Matchers.empty;
|
import static org.hamcrest.Matchers.empty;
|
||||||
|
@ -53,15 +47,12 @@ public class QuestionnaireResponseValidatorDstu3Test {
|
||||||
private static DefaultProfileValidationSupport myDefaultValidationSupport = new DefaultProfileValidationSupport();
|
private static DefaultProfileValidationSupport myDefaultValidationSupport = new DefaultProfileValidationSupport();
|
||||||
private static FhirContext ourCtx = FhirContext.forDstu3();
|
private static FhirContext ourCtx = FhirContext.forDstu3();
|
||||||
private FhirInstanceValidator myInstanceVal;
|
private FhirInstanceValidator myInstanceVal;
|
||||||
private static FhirValidator myVal;
|
private FhirValidator myVal;
|
||||||
private IValidationSupport myValSupport;
|
private IValidationSupport myValSupport;
|
||||||
private IWorkerContext myWorkerCtx;
|
|
||||||
|
|
||||||
@Before
|
@Before
|
||||||
public void before() {
|
public void before() {
|
||||||
myValSupport = mock(IValidationSupport.class);
|
myValSupport = mock(IValidationSupport.class);
|
||||||
// new DefaultProfileValidationSupport();
|
|
||||||
myWorkerCtx = new HapiWorkerContext(ourCtx, myValSupport);
|
|
||||||
|
|
||||||
myVal = ourCtx.newValidator();
|
myVal = ourCtx.newValidator();
|
||||||
myVal.setValidateAgainstStandardSchema(false);
|
myVal.setValidateAgainstStandardSchema(false);
|
||||||
|
@ -307,7 +298,7 @@ public class QuestionnaireResponseValidatorDstu3Test {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testRequiredQuestionWithEnableWhenHdesQuestionHasAnswerTrue() {
|
public void testRequiredQuestionWithEnableWhenHidesQuestionHasAnswerTrue() {
|
||||||
|
|
||||||
Questionnaire q = new Questionnaire();
|
Questionnaire q = new Questionnaire();
|
||||||
q.addItem().setLinkId("link0").setRequired(true).setType(QuestionnaireItemType.STRING);
|
q.addItem().setLinkId("link0").setRequired(true).setType(QuestionnaireItemType.STRING);
|
||||||
|
|
Loading…
Reference in New Issue