From 073a30f2faad28de16430efe2c8d4aee2f378747 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 19 Dec 2024 18:32:46 -0500 Subject: [PATCH] deps: bump com.puppycrawl.tools:checkstyle from 10.0 to 10.21.0 (#3417) * deps: bump com.puppycrawl.tools:checkstyle from 10.0 to 10.21.0 Bumps [com.puppycrawl.tools:checkstyle](https://github.com/checkstyle/checkstyle) from 10.0 to 10.21.0. - [Release notes](https://github.com/checkstyle/checkstyle/releases) - [Commits](https://github.com/checkstyle/checkstyle/compare/checkstyle-10.0...checkstyle-10.21.0) --- updated-dependencies: - dependency-name: com.puppycrawl.tools:checkstyle dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * reformat --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Joe Wang --- pom.xml | 2 +- .../GcpPubSubAutoConfigurationTests.java | 2 +- .../health/PubSubHealthIndicatorTests.java | 12 +++++----- .../TracePubSubBeanPostProcessorTest.java | 4 ++-- .../BigQueryFileMessageHandlerTests.java | 4 ++-- .../data/datastore/core/util/KeyUtilTest.java | 4 ++-- .../it/SpannerRepositoryIntegrationTests.java | 16 ++++++------- .../pubsub/core/PubSubTemplateTests.java | 6 ++--- .../PubSubSubscriberTemplateTests.java | 24 +++++++++---------- .../PubSubInboundChannelAdapterTests.java | 2 +- .../DefaultSubscriberFactoryTests.java | 6 ++--- spring-cloud-gcp-samples/pom.xml | 2 +- 12 files changed, 42 insertions(+), 42 deletions(-) diff --git a/pom.xml b/pom.xml index cbf589125c..9fe7ebfe98 100644 --- a/pom.xml +++ b/pom.xml @@ -57,7 +57,7 @@ 17 1.7.0 3.5.0 - 10.0 + 10.21.0 2.0.0 0.10.3 2.34.0 diff --git a/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/pubsub/GcpPubSubAutoConfigurationTests.java b/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/pubsub/GcpPubSubAutoConfigurationTests.java index 8b72f9af70..7652d42213 100644 --- a/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/pubsub/GcpPubSubAutoConfigurationTests.java +++ b/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/pubsub/GcpPubSubAutoConfigurationTests.java @@ -167,7 +167,7 @@ void retryableCodes_empty() { } @Test - void retryableCodes_Internal() { + void retryableCodesInternal() { contextRunner .withPropertyValues("spring.cloud.gcp.pubsub.subscriber.retryableCodes=INTERNAL") .run( diff --git a/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/pubsub/health/PubSubHealthIndicatorTests.java b/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/pubsub/health/PubSubHealthIndicatorTests.java index 24ee9821cb..c64d5eec06 100644 --- a/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/pubsub/health/PubSubHealthIndicatorTests.java +++ b/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/pubsub/health/PubSubHealthIndicatorTests.java @@ -115,14 +115,14 @@ void randomSubscription_unexpectedErrorCode() throws Exception { } @Test - void randomSubscription_NotApiExcpetion() throws Exception { + void randomSubscriptionNotApiExcpetion() throws Exception { ExecutionException e = new ExecutionException("Exception", new IllegalArgumentException()); testHealth(e, null, Status.DOWN); } @ParameterizedTest @ValueSource(strings = {"NOT_FOUND", "PERMISSION_DENIED"}) - void customSubscription_ApiException(String code) throws Exception { + void customSubscriptionApiException(String code) throws Exception { Exception e = new ExecutionException( new ApiException(null, GrpcStatusCode.of(io.grpc.Status.Code.valueOf(code)), false)); @@ -130,25 +130,25 @@ void customSubscription_ApiException(String code) throws Exception { } @Test - void customSubscription_ExecutionException_NotApiException() throws Exception { + void customSubscriptionExecutionExceptionNotApiException() throws Exception { ExecutionException e = new ExecutionException("Exception", new IllegalArgumentException()); testHealth(e, "testSubscription", Status.DOWN); } @Test - void customSubscription_InterruptedException() throws Exception { + void customSubscriptionInterruptedException() throws Exception { Exception e = new InterruptedException("Interrupted"); testHealth(e, "testSubscription", Status.UNKNOWN); } @Test - void customSubscription_TimeoutException() throws Exception { + void customSubscriptionTimeoutException() throws Exception { Exception e = new TimeoutException("Timed out waiting for result"); testHealth(e, "testSubscription", Status.UNKNOWN); } @Test - void customSubscription_RuntimeException() throws Exception { + void customSubscriptionRuntimeException() throws Exception { Exception e = new RuntimeException("Runtime error"); testHealth(e, "testSubscription", Status.DOWN); } diff --git a/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/trace/pubsub/TracePubSubBeanPostProcessorTest.java b/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/trace/pubsub/TracePubSubBeanPostProcessorTest.java index c99bfeebfa..1f67f84a68 100644 --- a/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/trace/pubsub/TracePubSubBeanPostProcessorTest.java +++ b/spring-cloud-gcp-autoconfigure/src/test/java/com/google/cloud/spring/autoconfigure/trace/pubsub/TracePubSubBeanPostProcessorTest.java @@ -37,7 +37,7 @@ final class TracePubSubBeanPostProcessorTest { new TracePubSubBeanPostProcessor(mockBeanFactory); @Test - void test_postProcessBeforeInitialization_SubscriberFactory() { + void test_postProcessBeforeInitializationSubscriberFactory() { SubscriberFactory mockSubscriberFactory = mock(SubscriberFactory.class); Object result = @@ -48,7 +48,7 @@ void test_postProcessBeforeInitialization_SubscriberFactory() { } @Test - void test_postProcessBeforeInitialization_Other() { + void test_postProcessBeforeInitializationOther() { PubSubTemplate mockOther = mock(PubSubTemplate.class); Object result = diff --git a/spring-cloud-gcp-bigquery/src/test/java/com/google/cloud/spring/bigquery/integration/outbound/BigQueryFileMessageHandlerTests.java b/spring-cloud-gcp-bigquery/src/test/java/com/google/cloud/spring/bigquery/integration/outbound/BigQueryFileMessageHandlerTests.java index 29a2fb52f1..93cb61ac64 100644 --- a/spring-cloud-gcp-bigquery/src/test/java/com/google/cloud/spring/bigquery/integration/outbound/BigQueryFileMessageHandlerTests.java +++ b/spring-cloud-gcp-bigquery/src/test/java/com/google/cloud/spring/bigquery/integration/outbound/BigQueryFileMessageHandlerTests.java @@ -122,7 +122,7 @@ void testHandleMessage_sync() { } @Test - void testHandleMessage_ThrowsExecutionExceptionTest() + void testHandleMessageThrowsExecutionExceptionTest() throws ExecutionException, InterruptedException, TimeoutException { CompletableFuture mockCompletableFuture = mock(CompletableFuture.class); when(bigQueryTemplate.writeDataToTable(any(), any(), any(), any())).thenReturn( @@ -142,7 +142,7 @@ void testHandleMessage_ThrowsExecutionExceptionTest() } @Test - void testHandleMessage_ThrowsInterruptedExceptionTest() + void testHandleMessageThrowsInterruptedExceptionTest() throws ExecutionException, InterruptedException, TimeoutException { CompletableFuture mockCompletableFuture = mock(CompletableFuture.class); when(bigQueryTemplate.writeDataToTable(any(), any(), any(), any())).thenReturn( diff --git a/spring-cloud-gcp-data-datastore/src/test/java/com/google/cloud/spring/data/datastore/core/util/KeyUtilTest.java b/spring-cloud-gcp-data-datastore/src/test/java/com/google/cloud/spring/data/datastore/core/util/KeyUtilTest.java index 964e1340c0..56931bddd5 100644 --- a/spring-cloud-gcp-data-datastore/src/test/java/com/google/cloud/spring/data/datastore/core/util/KeyUtilTest.java +++ b/spring-cloud-gcp-data-datastore/src/test/java/com/google/cloud/spring/data/datastore/core/util/KeyUtilTest.java @@ -25,7 +25,7 @@ class KeyUtilTest { @Test - void testRemoveAncestors_NamedKeys() { + void testRemoveAncestorsNamedKeys() { Key namedKey = Key.newBuilder("project", "person", "Smith") .addAncestor(PathElement.of("person", "GrandParent")) @@ -37,7 +37,7 @@ void testRemoveAncestors_NamedKeys() { } @Test - void testRemoveAncestors_IdKeys() { + void testRemoveAncestorsIdKeys() { Key idKey = Key.newBuilder("project", "person", 46L) .addAncestor(PathElement.of("person", 22L)) diff --git a/spring-cloud-gcp-data-spanner/src/test/java/com/google/cloud/spring/data/spanner/repository/it/SpannerRepositoryIntegrationTests.java b/spring-cloud-gcp-data-spanner/src/test/java/com/google/cloud/spring/data/spanner/repository/it/SpannerRepositoryIntegrationTests.java index 5b724aab10..d6e1691439 100644 --- a/spring-cloud-gcp-data-spanner/src/test/java/com/google/cloud/spring/data/spanner/repository/it/SpannerRepositoryIntegrationTests.java +++ b/spring-cloud-gcp-data-spanner/src/test/java/com/google/cloud/spring/data/spanner/repository/it/SpannerRepositoryIntegrationTests.java @@ -148,7 +148,7 @@ void queryMethodsTest_updateActionTradeById() { } @Test - void queryMethodsTest_BoundParameters() { + void queryMethodsTestBoundParameters() { insertTrades("trader1", "BUY", 3); insertTrades("trader1", "SELL", 2); insertTrades("trader2", "SELL", 3); @@ -251,7 +251,7 @@ void queryMethodsTest_readsAndCounts() { } @Test - void queryMethodsTest_Trader2() { + void queryMethodsTestTrader2() { List trader2Trades = insertTrades("trader2", "SELL", 3); List trader2TradesRetrieved = this.tradeRepository.findByTraderId("trader2"); @@ -340,7 +340,7 @@ void queryMethodsTest_sortingAndPaging() { } @Test - void queryMethodsTest_CustomSort() { + void queryMethodsTestCustomSort() { insertTrades("trader1", "BUY", 3); insertTrades("trader1", "SELL", 2); insertTrades("trader2", "SELL", 3); @@ -354,7 +354,7 @@ void queryMethodsTest_CustomSort() { } @Test - void queryMethodsTest_Wildcards() { + void queryMethodsTestWildcards() { insertTrades("trader1", "BUY", 3); this.tradeRepository @@ -376,7 +376,7 @@ void queryMethodsTest_Wildcards() { } @Test - void queryMethodsTest_NullColumns() { + void queryMethodsTestNullColumns() { insertTrades("trader1", "BUY", 3); Trade someTrade = this.tradeRepository.findBySymbolContains("ABCD").get(0); @@ -394,7 +394,7 @@ void queryMethodsTest_NullColumns() { } @Test - void queryMethodsTest_ParentChildOperations() { + void queryMethodsTestParentChildOperations() { insertTrades("trader1", "BUY", 3); Trade someTrade = this.tradeRepository.findBySymbolContains("ABCD").get(0); @@ -464,7 +464,7 @@ void queryMethodsTest_ParentChildOperations() { } @Test - void queryMethodsTest_EagerFetch() { + void queryMethodsTestEagerFetch() { final Trade aTrade = Trade.makeTrade("trader1", 0, 0); aTrade.setAction("BUY"); aTrade.setSymbol("ABCD"); @@ -480,7 +480,7 @@ void queryMethodsTest_EagerFetch() { } @Test - void queryMethodsTest_SoftDelete() { + void queryMethodsTestSoftDelete() { Trade someTrade = insertTrade("trader1", "BUY", 1); SubTrade subTrade1 = new SubTrade(someTrade.getTradeDetail().getId(), someTrade.getTraderId(), "subTrade1"); diff --git a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/core/PubSubTemplateTests.java b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/core/PubSubTemplateTests.java index e2f2759b3c..7d158bc0d6 100644 --- a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/core/PubSubTemplateTests.java +++ b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/core/PubSubTemplateTests.java @@ -103,7 +103,7 @@ void testPublish() throws ExecutionException, InterruptedException { } @Test - void testPublish_String() { + void testPublishString() { when(this.mockPublisherFactory.createPublisher("testTopic")).thenReturn(this.mockPublisher); when(this.mockPublisher.publish(isA(PubsubMessage.class))).thenReturn(this.settableApiFuture); this.pubSubTemplate.publish("testTopic", "testPayload"); @@ -112,7 +112,7 @@ void testPublish_String() { } @Test - void testPublish_Bytes() { + void testPublishBytes() { when(this.mockPublisherFactory.createPublisher("testTopic")).thenReturn(this.mockPublisher); when(this.mockPublisher.publish(isA(PubsubMessage.class))).thenReturn(this.settableApiFuture); this.pubSubTemplate.publish("testTopic", "testPayload".getBytes()); @@ -121,7 +121,7 @@ void testPublish_Bytes() { } @Test - void testPublish_Object() throws IOException { + void testPublishObject() { AllowedPayload allowedPayload = new AllowedPayload(); allowedPayload.name = "allowed"; allowedPayload.value = 12345; diff --git a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/core/subscriber/PubSubSubscriberTemplateTests.java b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/core/subscriber/PubSubSubscriberTemplateTests.java index 1f741fffa7..69aa95145a 100644 --- a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/core/subscriber/PubSubSubscriberTemplateTests.java +++ b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/core/subscriber/PubSubSubscriberTemplateTests.java @@ -199,7 +199,7 @@ void setUp() throws ExecutionException, InterruptedException { } @Test - void testSubscribe_AndManualAck() + void testSubscribeAndManualAck() throws InterruptedException, ExecutionException, TimeoutException { this.pubSubSubscriberTemplate.subscribe("sub1", this.consumer); @@ -223,7 +223,7 @@ void testSubscribe_AndManualAck() } @Test - void testSubscribe_AndManualNack() + void testSubscribeAndManualNack() throws InterruptedException, ExecutionException, TimeoutException { this.pubSubSubscriberTemplate.subscribe("sub1", this.consumer); @@ -247,7 +247,7 @@ void testSubscribe_AndManualNack() } @Test - void testSubscribeAndConvert_AndManualAck() + void testSubscribeAndConvertAndManualAck() throws InterruptedException, ExecutionException, TimeoutException { this.pubSubSubscriberTemplate.subscribeAndConvert( "sub1", this.convertedConsumer, Boolean.class); @@ -279,7 +279,7 @@ void testSubscribeAndConvert_AndManualAck() } @Test - void testSubscribeAndConvert_AndManualNack() + void testSubscribeAndConvertAndManualNack() throws InterruptedException, ExecutionException, TimeoutException { this.pubSubSubscriberTemplate.subscribeAndConvert( "sub1", this.convertedConsumer, Boolean.class); @@ -325,7 +325,7 @@ void destroyingBeanClosesSubscriberStub() { } @Test - void testPull_AndManualAck() + void testPullAndManualAck() throws InterruptedException, ExecutionException, TimeoutException { List result = this.pubSubSubscriberTemplate.pull("sub2", 1, true); @@ -353,7 +353,7 @@ void testPull_AndManualAck() } @Test - void testPull_AndManualNack() + void testPullAndManualNack() throws InterruptedException, ExecutionException, TimeoutException { List result = this.pubSubSubscriberTemplate.pull("sub2", 1, true); @@ -380,7 +380,7 @@ void testPull_AndManualNack() } @Test - void testPull_AndManualMultiSubscriptionAck() + void testPullAndManualMultiSubscriptionAck() throws InterruptedException, ExecutionException, TimeoutException { ExecutorService mockExecutor = Mockito.mock(ExecutorService.class); this.pubSubSubscriberTemplate.setAckExecutor(mockExecutor); @@ -409,7 +409,7 @@ void testPull_AndManualMultiSubscriptionAck() } @Test - void testPullAsync_AndManualAck() + void testPullAsyncAndManualAck() throws InterruptedException, ExecutionException, TimeoutException { CompletableFuture> asyncResult = @@ -455,7 +455,7 @@ void testPullAndAck() { } @Test - void testPullAndAck_NoMessages() { + void testPullAndAckNoMessages() { when(this.pullCallable.call(any(PullRequest.class))) .thenReturn(PullResponse.newBuilder().build()); @@ -484,7 +484,7 @@ void testPullAndAckAsync() } @Test - void testPullAndAckAsync_NoMessages() + void testPullAndAckAsyncNoMessages() throws InterruptedException, ExecutionException, TimeoutException { when(this.pullApiFuture.get()).thenReturn(PullResponse.newBuilder().build()); @@ -542,7 +542,7 @@ void testPullNext() { } @Test - void testPullNext_NoMessages() { + void testPullNextNoMessages() { when(this.pullCallable.call(any(PullRequest.class))) .thenReturn(PullResponse.newBuilder().build()); @@ -570,7 +570,7 @@ void testPullNextAsync() } @Test - void testPullNextAsync_NoMessages() + void testPullNextAsyncNoMessages() throws InterruptedException, ExecutionException, TimeoutException { when(this.pullApiFuture.get()).thenReturn(PullResponse.newBuilder().build()); diff --git a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/integration/inbound/PubSubInboundChannelAdapterTests.java b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/integration/inbound/PubSubInboundChannelAdapterTests.java index 05289026e6..3e861b51d7 100644 --- a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/integration/inbound/PubSubInboundChannelAdapterTests.java +++ b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/integration/inbound/PubSubInboundChannelAdapterTests.java @@ -187,7 +187,7 @@ void testAckModeAutoAck_neitherAcksNorNacksWhenMessageProcessingFails(CapturedOu } @Test - void testSetHealthRegistry_Success() { + void testSetHealthRegistrySuccess() { setupSubscribeAndConvert(); HealthTrackerRegistry healthTrackerRegistry = mock(HealthTrackerRegistry.class); diff --git a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/support/DefaultSubscriberFactoryTests.java b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/support/DefaultSubscriberFactoryTests.java index 78ea14b328..204fe7387f 100644 --- a/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/support/DefaultSubscriberFactoryTests.java +++ b/spring-cloud-gcp-pubsub/src/test/java/com/google/cloud/spring/pubsub/support/DefaultSubscriberFactoryTests.java @@ -401,7 +401,7 @@ void testCreateSubscriber_invalidMinDurationPerAckExtension_throwsException() { assertThatThrownBy( () -> factory.createSubscriber( "defaultSubscription", - (message, consumer) -> { } + (message, consumer) -> {} )) .isExactlyInstanceOf(IllegalArgumentException.class); } @@ -419,7 +419,7 @@ void testCreateSubscriber_invalidMaxDurationPerAckExtension_throwsException() { assertThatThrownBy( () -> factory.createSubscriber( "defaultSubscription", - (message, consumer) -> { } + (message, consumer) -> {} )) .isExactlyInstanceOf(IllegalArgumentException.class); } @@ -440,7 +440,7 @@ void testCreateSubscriber_invalidDurationPerAckExtensions_throwsException() { assertThatThrownBy( () -> factory.createSubscriber( "defaultSubscription", - (message, consumer) -> { } + (message, consumer) -> {} )) .isExactlyInstanceOf(IllegalArgumentException.class); } diff --git a/spring-cloud-gcp-samples/pom.xml b/spring-cloud-gcp-samples/pom.xml index 6e128e6b76..a4d79ca984 100644 --- a/spring-cloud-gcp-samples/pom.xml +++ b/spring-cloud-gcp-samples/pom.xml @@ -22,7 +22,7 @@ 3.5.0 - 10.0 + 10.21.0 2.8.1