@Test public void testInitDataRequiredFields() { bootstrapBean.initData(); ArgumentCaptor<IntegreradEnhet> enhetCaptor = ArgumentCaptor.forClass(IntegreradEnhet.class); verify(integreradEnhetRepository, atLeastOnce()).save(enhetCaptor.capture()); for (IntegreradEnhet enhet : enhetCaptor.getAllValues()) { assertNotNull(enhet.getEnhetsId()); assertNotNull(enhet.getEnhetsNamn()); assertNotNull(enhet.getVardgivarId()); assertNotNull(enhet.getVardgivarNamn()); } }
@PostConstruct public void initData() { List<Resource> files = getResourceListing("bootstrap-integrerade-enheter/*.json"); for (Resource res : files) { LOG.debug("Loading resource " + res.getFilename()); addIntegreradEnhet(res); } }
IntegreradeEnheterBootstrapBean { @PostConstruct public void initData() { List<Resource> files = getResourceListing("bootstrap-integrerade-enheter/*.json"); for (Resource res : files) { LOG.debug("Loading resource " + res.getFilename()); addIntegreradEnhet(res); } } }
IntegreradeEnheterBootstrapBean { @PostConstruct public void initData() { List<Resource> files = getResourceListing("bootstrap-integrerade-enheter/*.json"); for (Resource res : files) { LOG.debug("Loading resource " + res.getFilename()); addIntegreradEnhet(res); } }  }
IntegreradeEnheterBootstrapBean { @PostConstruct public void initData() { List<Resource> files = getResourceListing("bootstrap-integrerade-enheter/*.json"); for (Resource res : files) { LOG.debug("Loading resource " + res.getFilename()); addIntegreradEnhet(res); } }  @PostConstruct void initData(); }
IntegreradeEnheterBootstrapBean { @PostConstruct public void initData() { List<Resource> files = getResourceListing("bootstrap-integrerade-enheter/*.json"); for (Resource res : files) { LOG.debug("Loading resource " + res.getFilename()); addIntegreradEnhet(res); } }  @PostConstruct void initData();  }