ResteasyAutoConfiguration { @Bean @Qualifier("ResteasyProviderFactory") public static BeanFactoryPostProcessor springBeanProcessor() { ResteasyProviderFactory resteasyProviderFactory = new ResteasyProviderFactory(); ResourceMethodRegistry resourceMethodRegistry = new ResourceMethodRegistry(resteasyProviderFactory); SpringBeanProcessor springBeanProcessor = new SpringBeanProcessor(); springBeanProcessor.setProviderFactory(resteasyProviderFactory); springBeanProcessor.setRegistry(resourceMethodRegistry); logger.debug("SpringBeanProcessor has been created"); return springBeanProcessor; }  @Bean @Qualifier("ResteasyProviderFactory") static BeanFactoryPostProcessor springBeanProcessor(); @Bean ServletContextListener resteasyBootstrapListener(@Qualifier("ResteasyProviderFactory") final BeanFactoryPostProcessor beanFactoryPostProcessor); @Bean(name = ResteasyApplicationBuilder.BEAN_NAME) ResteasyApplicationBuilder resteasyApplicationBuilder(); @Bean static ResteasyEmbeddedServletInitializer resteasyEmbeddedServletInitializer();  }
@Test public void springBeanProcessor() { BeanFactoryPostProcessor beanFactoryPostProcessor = new ResteasyAutoConfiguration().springBeanProcessor(); Assert.assertNotNull(beanFactoryPostProcessor); Assert.assertEquals(SpringBeanProcessor.class, beanFactoryPostProcessor.getClass()); SpringBeanProcessor springBeanProcessor = (SpringBeanProcessor) beanFactoryPostProcessor; Registry springBeanProcessorRegistry = springBeanProcessor.getRegistry(); ResteasyProviderFactory providerFactory = springBeanProcessor.getProviderFactory(); Assert.assertNotNull(springBeanProcessorRegistry); Assert.assertNotNull(providerFactory); Assert.assertEquals(ResourceMethodRegistry.class, springBeanProcessorRegistry.getClass()); }