@@ -48,27 +48,27 @@ public class StreamableHttpWebFluxTransportAutoConfigurationTests {
48
48
@ Test
49
49
void webFluxClientTransportsPresentIfWebClientStreamableHttpTransportPresent () {
50
50
this .applicationContext
51
- .run (context -> assertThat (context .containsBean ("streamableHttpwebFluxClientTransports " )).isTrue ());
51
+ .run (context -> assertThat (context .containsBean ("streamableHttpWebFluxClientTransports " )).isTrue ());
52
52
}
53
53
54
54
@ Test
55
55
void webFluxClientTransportsNotPresentIfMissingWebClientStreamableHttpTransportNotPresent () {
56
56
this .applicationContext
57
57
.withClassLoader (new FilteredClassLoader (
58
58
"io.modelcontextprotocol.client.transport.WebClientStreamableHttpTransport" ))
59
- .run (context -> assertThat (context .containsBean ("streamableHttpwebFluxClientTransports " )).isFalse ());
59
+ .run (context -> assertThat (context .containsBean ("streamableHttpWebFluxClientTransports " )).isFalse ());
60
60
}
61
61
62
62
@ Test
63
63
void webFluxClientTransportsNotPresentIfMcpClientDisabled () {
64
64
this .applicationContext .withPropertyValues ("spring.ai.mcp.client.enabled" , "false" )
65
- .run (context -> assertThat (context .containsBean ("streamableHttpwebFluxClientTransports " )).isFalse ());
65
+ .run (context -> assertThat (context .containsBean ("streamableHttpWebFluxClientTransports " )).isFalse ());
66
66
}
67
67
68
68
@ Test
69
69
void noTransportsCreatedWithEmptyConnections () {
70
70
this .applicationContext .run (context -> {
71
- List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpwebFluxClientTransports " ,
71
+ List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpWebFluxClientTransports " ,
72
72
List .class );
73
73
assertThat (transports ).isEmpty ();
74
74
});
@@ -79,7 +79,7 @@ void singleConnectionCreatesOneTransport() {
79
79
this .applicationContext
80
80
.withPropertyValues ("spring.ai.mcp.client.streamable-http.connections.server1.url=http://localhost:8080" )
81
81
.run (context -> {
82
- List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpwebFluxClientTransports " ,
82
+ List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpWebFluxClientTransports " ,
83
83
List .class );
84
84
assertThat (transports ).hasSize (1 );
85
85
assertThat (transports .get (0 ).name ()).isEqualTo ("server1" );
@@ -93,7 +93,7 @@ void multipleConnectionsCreateMultipleTransports() {
93
93
.withPropertyValues ("spring.ai.mcp.client.streamable-http.connections.server1.url=http://localhost:8080" ,
94
94
"spring.ai.mcp.client.streamable-http.connections.server2.url=http://otherserver:8081" )
95
95
.run (context -> {
96
- List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpwebFluxClientTransports " ,
96
+ List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpWebFluxClientTransports " ,
97
97
List .class );
98
98
assertThat (transports ).hasSize (2 );
99
99
assertThat (transports ).extracting ("name" ).containsExactlyInAnyOrder ("server1" , "server2" );
@@ -113,7 +113,7 @@ void customStreamableHttpEndpointIsRespected() {
113
113
.withPropertyValues ("spring.ai.mcp.client.streamable-http.connections.server1.url=http://localhost:8080" ,
114
114
"spring.ai.mcp.client.streamable-http.connections.server1.endpoint=/custom-mcp" )
115
115
.run (context -> {
116
- List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpwebFluxClientTransports " ,
116
+ List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpWebFluxClientTransports " ,
117
117
List .class );
118
118
assertThat (transports ).hasSize (1 );
119
119
assertThat (transports .get (0 ).name ()).isEqualTo ("server1" );
@@ -130,7 +130,7 @@ void customWebClientBuilderIsUsed() {
130
130
.withPropertyValues ("spring.ai.mcp.client.streamable-http.connections.server1.url=http://localhost:8080" )
131
131
.run (context -> {
132
132
assertThat (context .getBean (WebClient .Builder .class )).isNotNull ();
133
- List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpwebFluxClientTransports " ,
133
+ List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpWebFluxClientTransports " ,
134
134
List .class );
135
135
assertThat (transports ).hasSize (1 );
136
136
});
@@ -142,7 +142,7 @@ void customObjectMapperIsUsed() {
142
142
.withPropertyValues ("spring.ai.mcp.client.streamable-http.connections.server1.url=http://localhost:8080" )
143
143
.run (context -> {
144
144
assertThat (context .getBean (ObjectMapper .class )).isNotNull ();
145
- List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpwebFluxClientTransports " ,
145
+ List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpWebFluxClientTransports " ,
146
146
List .class );
147
147
assertThat (transports ).hasSize (1 );
148
148
});
@@ -153,7 +153,7 @@ void defaultStreamableHttpEndpointIsUsedWhenNotSpecified() {
153
153
this .applicationContext
154
154
.withPropertyValues ("spring.ai.mcp.client.streamable-http.connections.server1.url=http://localhost:8080" )
155
155
.run (context -> {
156
- List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpwebFluxClientTransports " ,
156
+ List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpWebFluxClientTransports " ,
157
157
List .class );
158
158
assertThat (transports ).hasSize (1 );
159
159
assertThat (transports .get (0 ).name ()).isEqualTo ("server1" );
@@ -170,7 +170,7 @@ void mixedConnectionsWithAndWithoutCustomStreamableHttpEndpoint() {
170
170
"spring.ai.mcp.client.streamable-http.connections.server1.endpoint=/custom-mcp" ,
171
171
"spring.ai.mcp.client.streamable-http.connections.server2.url=http://otherserver:8081" )
172
172
.run (context -> {
173
- List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpwebFluxClientTransports " ,
173
+ List <NamedClientMcpTransport > transports = context .getBean ("streamableHttpWebFluxClientTransports " ,
174
174
List .class );
175
175
assertThat (transports ).hasSize (2 );
176
176
assertThat (transports ).extracting ("name" ).containsExactlyInAnyOrder ("server1" , "server2" );
0 commit comments