### Question:
ServiceBean extends ServiceConfig<T> implements InitializingBean, DisposableBean,
        ApplicationContextAware, ApplicationListener<ContextRefreshedEvent>, BeanNameAware,
        ApplicationEventPublisherAware { public Service getService() { return service; } ServiceBean();  ServiceBean(Service service); static ApplicationContext getSpringContext(); @Override void setApplicationContext(ApplicationContext applicationContext); @Override void setBeanName(String name); Service getService(); @Override void onApplicationEvent(ContextRefreshedEvent event); @Override @SuppressWarnings({"unchecked", "deprecation"}) void afterPropertiesSet(); String getBeanName(); @Override void export(); @Override void destroy(); @Override void setApplicationEventPublisher(ApplicationEventPublisher applicationEventPublisher);  }### Answer:
@Test public void testGetService() { TestService service = mock(TestService.class); ServiceBean serviceBean = new ServiceBean(service); Service beanService = serviceBean.getService(); Assert.assertThat(beanService, not(nullValue())); }