@Test public void testCreateForSuccess() throws Exception { Measure measure = createGriffinMeasure("view_item_hourly"); given(measureRepo.save(measure)).willReturn(measure); Measure m = operator.create(measure); assertEquals(m.getName(), measure.getName()); }
@Override public Measure create(Measure measure) { validateMeasure(measure); return measureRepo.save(measure); }
GriffinMeasureOperatorImpl implements MeasureOperator { @Override public Measure create(Measure measure) { validateMeasure(measure); return measureRepo.save(measure); } }
GriffinMeasureOperatorImpl implements MeasureOperator { @Override public Measure create(Measure measure) { validateMeasure(measure); return measureRepo.save(measure); } @Autowired  GriffinMeasureOperatorImpl(MeasureRepo<Measure> measureRepo,
                                      JobServiceImpl jobService); }
GriffinMeasureOperatorImpl implements MeasureOperator { @Override public Measure create(Measure measure) { validateMeasure(measure); return measureRepo.save(measure); } @Autowired  GriffinMeasureOperatorImpl(MeasureRepo<Measure> measureRepo,
                                      JobServiceImpl jobService); @Override Measure create(Measure measure); @Override Measure update(Measure measure); @Override void delete(Measure measure); }
GriffinMeasureOperatorImpl implements MeasureOperator { @Override public Measure create(Measure measure) { validateMeasure(measure); return measureRepo.save(measure); } @Autowired  GriffinMeasureOperatorImpl(MeasureRepo<Measure> measureRepo,
                                      JobServiceImpl jobService); @Override Measure create(Measure measure); @Override Measure update(Measure measure); @Override void delete(Measure measure);  }