@@ -467,39 +467,6 @@ void testDuplicatePenRule() {
467
467
assertThat (validationDigitError .get (0 ).getValidationIssueCode ()).isEqualTo ("PENCHECKDIGITERR" );
468
468
}
469
469
470
- @ Test
471
- void testDuplicatePenRuleFound () {
472
- var collection = collectionRepository .save (createMockCollectionEntity ());
473
- var sdcSchoolCollectionEntity = sdcSchoolCollectionRepository .save (createMockSdcSchoolCollectionEntity (collection , null ));
474
- val entity = createMockSchoolStudentEntity (sdcSchoolCollectionEntity );
475
- entity .setEnrolledGradeCode ("08" );
476
- entity .setStudentPen ("120164447" );
477
- entity .setCreateDate (LocalDateTime .now ().minusMinutes (14 ));
478
- entity .setUpdateDate (LocalDateTime .now ());
479
- entity .setCreateUser (ApplicationProperties .STUDENT_DATA_COLLECTION_API );
480
- entity .setUpdateUser (ApplicationProperties .STUDENT_DATA_COLLECTION_API );
481
-
482
- val entity2 = createMockSchoolStudentEntity (sdcSchoolCollectionEntity );
483
- entity2 .setStudentPen ("120164447" );
484
- entity2 .setCreateDate (LocalDateTime .now ().minusMinutes (14 ));
485
- entity2 .setUpdateDate (LocalDateTime .now ());
486
- entity2 .setCreateUser (ApplicationProperties .STUDENT_DATA_COLLECTION_API );
487
- entity2 .setUpdateUser (ApplicationProperties .STUDENT_DATA_COLLECTION_API );
488
- sdcSchoolCollectionStudentRepository .save (entity2 );
489
-
490
- val savedEntityTwo = sdcSchoolCollectionStudentRepository .findById (entity2 .getSdcSchoolCollectionStudentID ());
491
- assertThat (savedEntityTwo ).isPresent ();
492
-
493
- val dupePenCount = sdcSchoolCollectionStudentRepository .countForDuplicateStudentPENs (entity .getSdcSchoolCollection ().getSdcSchoolCollectionID (), entity .getStudentPen ());
494
- assertThat (dupePenCount ).isEqualTo (1 );
495
-
496
- entity .setStudentPen ("120164447" );
497
- PenMatchResult penMatchResult = getPenMatchResult ();
498
- when (this .restUtils .getPenMatchResult (any (),any (), anyString ())).thenReturn (penMatchResult );
499
- val validationErrorDupe = rulesProcessor .processRules (createMockStudentRuleData (entity , createMockSchool ()));
500
- assertThat (validationErrorDupe .size ()).isNotZero ();
501
- }
502
-
503
470
@ Test
504
471
void testHomeSchoolRule () {
505
472
var collection = collectionRepository .save (createMockCollectionEntity ());
0 commit comments