use of gov.ca.cwds.cals.persistence.DBUnitAssertHelper in project cals-api by ca-cwds.
the class RFA1aCoreSubmitApplicationTest method testIfClientScpEthnicityWasCreatedProperly.
private void testIfClientScpEthnicityWasCreatedProperly(String substituteCareProviderId, String ethnicityId) throws Exception {
DBUnitAssertHelper helper = DBUnitAssertHelper.builder(dbUnitSupport).setExpectedResultTemplatePath("/dbunit/ClientScpEthnicity.xml").appendTemplateParameter("scpId", substituteCareProviderId).appendTemplateParameter("ethnicityId", ethnicityId).setTestedTableName("CLSCP_ET").appendTableFilter("ESTBLSH_ID", substituteCareProviderId).build();
helper.assertEquals(new String[] { "IDENTIFIER", "LST_UPD_TS" });
}
use of gov.ca.cwds.cals.persistence.DBUnitAssertHelper in project cals-api by ca-cwds.
the class RFA1aCoreSubmitApplicationTest method testIfBackgroundCheckWasCreatedProperly.
private void testIfBackgroundCheckWasCreatedProperly() throws Exception {
DBUnitAssertHelper helper = DBUnitAssertHelper.builder(dbUnitSupport).setExpectedResultTemplatePath("/dbunit/BackgroundCheck.xml").setTestedTableName("BKGRCHKT").build();
helper.assertEquals(new String[] { "IDENTIFIER", "BKGRCHK_DT", "LST_UPD_TS" });
}
use of gov.ca.cwds.cals.persistence.DBUnitAssertHelper in project cals-api by ca-cwds.
the class RFA1aCoreSubmitApplicationTest method testIfExternalInterfaceWasCreatedProperly.
private void testIfExternalInterfaceWasCreatedProperly() throws Exception {
DBUnitAssertHelper helper = DBUnitAssertHelper.builder(dbUnitSupport).setExpectedResultTemplatePath("/dbunit/ExternalInterface.xml").setTestedTableName("EXTINF_T").build();
helper.assertEquals(new String[] { "SUBMTL_TS" });
}
use of gov.ca.cwds.cals.persistence.DBUnitAssertHelper in project cals-api by ca-cwds.
the class RFA1aCoreSubmitApplicationTest method testIfPlacementHomeProfileWasCreatedProperly.
private void testIfPlacementHomeProfileWasCreatedProperly(String placementHomeId) throws Exception {
DBUnitAssertHelper helper = DBUnitAssertHelper.builder(dbUnitSupport).setExpectedResultTemplatePath("/dbunit/PlacementHomeProfile.xml").setTestedTableName("HM_PRFT").appendTableFilter("FKPLC_HM_T", placementHomeId).build();
ReplacementDataSet expectedDataSet = helper.getExpectedDataSet();
expectedDataSet.addReplacementObject("$placementHomeId", placementHomeId);
helper.assertEquals(new String[] { "THIRD_ID", "LST_UPD_TS" });
}
use of gov.ca.cwds.cals.persistence.DBUnitAssertHelper in project cals-api by ca-cwds.
the class RFA1aCoreSubmitApplicationTest method testIfOtherChildrenWasCreatedProperly.
private void testIfOtherChildrenWasCreatedProperly(String placementHomeId, RFA1aFormDTO form) throws Exception {
DBUnitAssertHelper helper = DBUnitAssertHelper.builder(dbUnitSupport).setExpectedResultTemplatePath("/dbunit/MinorChildrenInPlacementHome.xml").appendTemplateParameter("birthDate", form.getMinorChildren().get(0).getDateOfBirth().format(DateTimeFormatter.ofPattern(DATE_FORMAT))).setTestedTableName("OTH_KIDT").appendTableFilter("FKPLC_HM_T", placementHomeId).build();
helper.assertEquals(new String[] { "IDENTIFIER", "FKPLC_HM_T", "LST_UPD_TS" });
}
Aggregations