Added initial implementation of check for supported function signatures
This commit is contained in:
@@ -35,6 +35,7 @@ import reactor.core.publisher.Flux;
|
||||
import reactor.core.publisher.Mono;
|
||||
|
||||
import org.springframework.beans.BeansException;
|
||||
import org.springframework.beans.factory.BeanCreationException;
|
||||
import org.springframework.beans.factory.annotation.Qualifier;
|
||||
import org.springframework.beans.factory.config.AbstractFactoryBean;
|
||||
import org.springframework.beans.factory.config.BeanFactoryPostProcessor;
|
||||
@@ -289,6 +290,11 @@ public class ContextFunctionCatalogAutoConfigurationTests {
|
||||
.isAssignableFrom(Mono.class);
|
||||
}
|
||||
|
||||
@Test(expected = BeanCreationException.class)
|
||||
public void monoToMonoNonVoidFunction() {
|
||||
create(MonoToMonoNonVoidConfiguration.class);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void messageFunction() {
|
||||
create(MessageConfiguration.class);
|
||||
@@ -867,6 +873,17 @@ public class ContextFunctionCatalogAutoConfigurationTests {
|
||||
|
||||
}
|
||||
|
||||
@EnableAutoConfiguration
|
||||
@Configuration
|
||||
protected static class MonoToMonoNonVoidConfiguration {
|
||||
|
||||
@Bean
|
||||
public Function<Mono<String>, Mono<String>> function() {
|
||||
return mono -> mono;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@EnableAutoConfiguration
|
||||
@Configuration
|
||||
protected static class MessageConfiguration {
|
||||
|
||||
Reference in New Issue
Block a user