diff --git a/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/trace/pubsub/TraceHelperTests.java b/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/trace/pubsub/TraceHelperTests.java
index 648d449d49..44794b52b2 100644
--- a/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/trace/pubsub/TraceHelperTests.java
+++ b/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/trace/pubsub/TraceHelperTests.java
@@ -66,7 +66,6 @@ void should_inject_child_context() {
assertThat(producerSpan.kind()).isEqualTo(PRODUCER);
assertChildOf(producerSpan, parent);
assertThat(instrumentedMessage.getAttributesMap())
- .isNotNull()
.containsEntry("b3", producerSpan.traceId() + "-" + producerSpan.id() + "-1");
}
diff --git a/spring-cloud-gcp-dependencies/pom.xml b/spring-cloud-gcp-dependencies/pom.xml
index 6aa7ac6cbe..7bdc2df6ab 100644
--- a/spring-cloud-gcp-dependencies/pom.xml
+++ b/spring-cloud-gcp-dependencies/pom.xml
@@ -34,10 +34,11 @@
- 26.49.0
+ 26.51.0
1.21.0
1.0.7.RELEASE
1.3.0
+ 1.42.1
@@ -276,6 +277,14 @@
cloud-spanner-r2dbc
${cloud-spanner-r2dbc.version}
+
+
+ io.opentelemetry
+ opentelemetry-bom
+ ${opentelemetry.version}
+ pom
+ import
+
diff --git a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/support/DefaultPublisherFactoryTests.java b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/support/DefaultPublisherFactoryTests.java
index 1fc4e7df42..71b94953a1 100644
--- a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/support/DefaultPublisherFactoryTests.java
+++ b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/support/DefaultPublisherFactoryTests.java
@@ -19,6 +19,7 @@
import static org.assertj.core.api.Assertions.assertThat;
import static org.assertj.core.api.Assertions.assertThatThrownBy;
import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.ArgumentMatchers.anyBoolean;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
@@ -46,6 +47,7 @@ public void setUp() throws IOException {
factory.setCredentialsProvider(NoCredentialsProvider.create());
TransportChannelProvider mockChannelProvider = mock(TransportChannelProvider.class);
TransportChannel mockTransportChannel = mock(TransportChannel.class);
+ when(mockChannelProvider.withUseS2A(anyBoolean())).thenReturn(mockChannelProvider);
when(mockChannelProvider.getTransportChannel()).thenReturn(mockTransportChannel);
ApiCallContext mockContext = mock(ApiCallContext.class);
when(mockTransportChannel.getEmptyCallContext()).thenReturn(mockContext);
diff --git a/spring-cloud-previews/google-cloud-language-spring-starter/src/test/java/com/google/cloud/language/v2/spring/LanguageAutoConfigurationTests.java b/spring-cloud-previews/google-cloud-language-spring-starter/src/test/java/com/google/cloud/language/v2/spring/LanguageAutoConfigurationTests.java
index 2c6d3a6ab2..0f874a0330 100644
--- a/spring-cloud-previews/google-cloud-language-spring-starter/src/test/java/com/google/cloud/language/v2/spring/LanguageAutoConfigurationTests.java
+++ b/spring-cloud-previews/google-cloud-language-spring-starter/src/test/java/com/google/cloud/language/v2/spring/LanguageAutoConfigurationTests.java
@@ -18,6 +18,7 @@
import static org.assertj.core.api.Assertions.assertThat;
import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.ArgumentMatchers.anyBoolean;
import static org.mockito.Mockito.when;
import com.google.api.gax.core.CredentialsProvider;
@@ -53,10 +54,14 @@ class LanguageAutoConfigurationTests {
private static final String TRANSPORT_CHANNEL_PROVIDER_QUALIFIER_NAME =
"defaultLanguageServiceTransportChannelProvider";
- @Mock private TransportChannel mockTransportChannel;
- @Mock private ApiCallContext mockApiCallContext;
- @Mock private TransportChannelProvider mockTransportChannelProvider;
- @Mock private CredentialsProvider mockCredentialsProvider;
+ @Mock
+ private TransportChannel mockTransportChannel;
+ @Mock
+ private ApiCallContext mockApiCallContext;
+ @Mock
+ private TransportChannelProvider mockTransportChannelProvider;
+ @Mock
+ private CredentialsProvider mockCredentialsProvider;
private ApplicationContextRunner contextRunner =
new ApplicationContextRunner()
@@ -192,6 +197,8 @@ void testExecutorThreadCountFromProperties() {
void testCustomTransportChannelProviderUsedWhenProvided() throws IOException {
when(mockTransportChannelProvider.getTransportName()).thenReturn("grpc");
when(mockTransportChannelProvider.getTransportChannel()).thenReturn(mockTransportChannel);
+ when(mockTransportChannelProvider.withUseS2A(anyBoolean()))
+ .thenReturn(mockTransportChannelProvider);
when(mockTransportChannel.getEmptyCallContext()).thenReturn(mockApiCallContext);
when(mockApiCallContext.withCredentials(any())).thenReturn(mockApiCallContext);
when(mockApiCallContext.withTransportChannel(any())).thenReturn(mockApiCallContext);