@SuppressWarnings("unchecked")
 @Override
 public void dispatch(PendingReferenceCheck<T> reporter) {
   reference.dispatch(
       mock(
           (Class<PendingReferenceCheck<T>>) reporter.getClass(),
           withSettings()
               .spiedInstance(reporter)
               .defaultAnswer(new ReporterSpy<>(reference, reporter, log))));
 }
예제 #2
0
 void markInCustody() {
   PendingReferenceCheck<AbstractBaseRecord> reporter = pop();
   if (reporter != null) {
     reporter.skip();
   }
 }
예제 #3
0
 public void checkOrphanage() {
   PendingReferenceCheck<AbstractBaseRecord> reporter = pop();
   if (reporter != null) {
     reporter.checkReference(null, null);
   }
 }