DMPAInjectableStrategy implements FPMethodStrategy { @Override public void registerEC(FPProductInformation fpInfo) { enrollECToDMPAInjectableSchedule(fpInfo.entityId(), fpInfo.dmpaInjectionDate()); } @Autowired  DMPAInjectableStrategy(ScheduleTrackingService scheduleTrackingService, ActionService actionService, ScheduleService scheduleService); @Override void registerEC(FPProductInformation fpInfo); @Override void unEnrollFromPreviousScheduleAsFPMethodChanged(FPProductInformation fpInfo); @Override void enrollToNewScheduleForNewFPMethod(FPProductInformation fpInfo); @Override void renewFPProduct(FPProductInformation fpInfo); @Override void fpFollowup(FPProductInformation fpInfo);  }
@Test public void shouldEnrollInDMPAInjectableScheduleOnECRegistration() throws Exception { strategy.registerEC(new FPProductInformation("entity id 1", "anm id 1", "dmpa_injectable", null, "2012-01-01", null, null , "20", "2012-03-01", null, null, null, null)); verify(scheduleService).enroll("entity id 1", "DMPA Injectable Refill", "2012-01-01"); }