Skip to content

Commit

Permalink
fixing test and changing to localDateTime
Browse files Browse the repository at this point in the history
  • Loading branch information
soletsdev committed Sep 25, 2024
1 parent ef3f1d4 commit 3e24f1a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,7 @@ public void testProcessPenRegBatchFileFromTSW_GivenmincodeInvalidSchoolCloseDate
@Transactional
public void testProcessPenRegBatchFileFromTSW_GivenmincodeInvalidSchoolOpenDate_ShouldCreateRecordLOADFAILInDB() throws IOException {
final School school = this.createMockSchool();
school.setOpenedDate("2024-09-01T00:00:00");
school.setOpenedDate(LocalDateTime.now().plusYears(1).toString());
when(this.restUtils.getSchoolByMincode(anyString())).thenReturn(Optional.of(school));
final File file = new File(Objects.requireNonNull(this.getClass().getClassLoader().getResource("sample_5_K12_OK.txt")).getFile());
final byte[] bFile = Files.readAllBytes(file.toPath());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,9 @@ private GradeCode[] createGradeCodeArray() {
private SchoolContactSearchWrapper createSchoolContactSearchWrapper() {
SchoolContactSearchWrapper schoolSearchWrapper = new SchoolContactSearchWrapper();
schoolSearchWrapper.setContent(Arrays.asList(
SchoolContact.builder().email("expired@email.com").firstName("Joe").lastName("Blow").expiryDate(LocalDate.now().minusDays(1).toString()).build(),
SchoolContact.builder().email("expired@email.com").firstName("Joe").lastName("Blow").expiryDate(LocalDateTime.now().minusDays(1).toString()).build(),
SchoolContact.builder().email("active@email.com").firstName("2").lastName("2").expiryDate(null).build(),
SchoolContact.builder().email("active@email.com").firstName("Joe").lastName("Blow").expiryDate(LocalDate.now().plusDays(1).toString()).build()));
SchoolContact.builder().email("active@email.com").firstName("Joe").lastName("Blow").expiryDate(LocalDateTime.now().plusDays(1).toString()).build()));

return schoolSearchWrapper;
}
Expand Down

0 comments on commit 3e24f1a

Please sign in to comment.