Search in sources :

Example 1 with ca.bc.gov.educ.penreg.api.struct.v1

use of ca.bc.gov.educ.penreg.api.struct.v1 in project EDUC-PEN-REG-BATCH-API by bcgov.

the class PenRequestBatchRepostReportsOrchestratorTest method setUp.

@Before
public void setUp() throws Exception {
    MockitoAnnotations.openMocks(this);
    this.saga = penRequestBatchTestUtils.createSaga("19337120", "12345678", LOADED.getCode(), TEST_PEN);
    final File file = new File(Objects.requireNonNull(this.getClass().getClassLoader().getResource("mock-pen-coordinator.json")).getFile());
    final List<ca.bc.gov.educ.penreg.api.struct.v1.PenCoordinator> structs = new ObjectMapper().readValue(file, new TypeReference<>() {
    });
    when(this.restUtils.getProps()).thenReturn(this.props);
}
Also used : PenCoordinator(ca.bc.gov.educ.penreg.api.struct.v1.PenCoordinator) File(java.io.File) ObjectMapper(com.fasterxml.jackson.databind.ObjectMapper) Before(org.junit.Before)

Example 2 with ca.bc.gov.educ.penreg.api.struct.v1

use of ca.bc.gov.educ.penreg.api.struct.v1 in project EDUC-PEN-REG-BATCH-API by bcgov.

the class PenRequestBatchArchiveAndReturnOrchestratorTest method setUp.

@Before
public void setUp() throws Exception {
    MockitoAnnotations.openMocks(this);
    this.saga = penRequestBatchTestUtils.createSaga("19337120", "12345678", LOADED.getCode(), TEST_PEN);
    final File file = new File(Objects.requireNonNull(this.getClass().getClassLoader().getResource("mock-pen-coordinator.json")).getFile());
    final List<ca.bc.gov.educ.penreg.api.struct.v1.PenCoordinator> structs = new ObjectMapper().readValue(file, new TypeReference<>() {
    });
    when(this.restUtils.getProps()).thenReturn(this.props);
}
Also used : PenCoordinator(ca.bc.gov.educ.penreg.api.struct.v1.PenCoordinator) File(java.io.File) ObjectMapper(com.fasterxml.jackson.databind.ObjectMapper) Before(org.junit.Before)

Aggregations

PenCoordinator (ca.bc.gov.educ.penreg.api.struct.v1.PenCoordinator)2 ObjectMapper (com.fasterxml.jackson.databind.ObjectMapper)2 File (java.io.File)2 Before (org.junit.Before)2