Skip to content

Commit

Permalink
deps: bump com.puppycrawl.tools:checkstyle from 10.0 to 10.21.0 (#3417)
Browse files Browse the repository at this point in the history
* 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](checkstyle/checkstyle@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] <[email protected]>

* reformat

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joe Wang <[email protected]>
  • Loading branch information
dependabot[bot] and JoeWang1127 authored Dec 19, 2024
1 parent 998399d commit 073a30f
Show file tree
Hide file tree
Showing 12 changed files with 42 additions and 42 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
<maven.compiler.target>17</maven.compiler.target>
<nexus-staging-plugin.version>1.7.0</nexus-staging-plugin.version>
<maven-checkstyle-plugin.version>3.5.0</maven-checkstyle-plugin.version>
<checkstyle-rules.version>10.0</checkstyle-rules.version>
<checkstyle-rules.version>10.21.0</checkstyle-rules.version>
<asciidoctor-maven-plugin.version>2.0.0</asciidoctor-maven-plugin.version>
<native-maven-plugin.version>0.10.3</native-maven-plugin.version>
<errorprone.version>2.34.0</errorprone.version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ void retryableCodes_empty() {
}

@Test
void retryableCodes_Internal() {
void retryableCodesInternal() {
contextRunner
.withPropertyValues("spring.cloud.gcp.pubsub.subscriber.retryableCodes=INTERNAL")
.run(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,40 +115,40 @@ 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));
testHealth(e, "testSubscription", Status.DOWN);
}

@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);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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 =
Expand All @@ -48,7 +48,7 @@ void test_postProcessBeforeInitialization_SubscriberFactory() {
}

@Test
void test_postProcessBeforeInitialization_Other() {
void test_postProcessBeforeInitializationOther() {
PubSubTemplate mockOther = mock(PubSubTemplate.class);

Object result =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ void testHandleMessage_sync() {
}

@Test
void testHandleMessage_ThrowsExecutionExceptionTest()
void testHandleMessageThrowsExecutionExceptionTest()
throws ExecutionException, InterruptedException, TimeoutException {
CompletableFuture<Job> mockCompletableFuture = mock(CompletableFuture.class);
when(bigQueryTemplate.writeDataToTable(any(), any(), any(), any())).thenReturn(
Expand All @@ -142,7 +142,7 @@ void testHandleMessage_ThrowsExecutionExceptionTest()
}

@Test
void testHandleMessage_ThrowsInterruptedExceptionTest()
void testHandleMessageThrowsInterruptedExceptionTest()
throws ExecutionException, InterruptedException, TimeoutException {
CompletableFuture<Job> mockCompletableFuture = mock(CompletableFuture.class);
when(bigQueryTemplate.writeDataToTable(any(), any(), any(), any())).thenReturn(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
class KeyUtilTest {

@Test
void testRemoveAncestors_NamedKeys() {
void testRemoveAncestorsNamedKeys() {
Key namedKey =
Key.newBuilder("project", "person", "Smith")
.addAncestor(PathElement.of("person", "GrandParent"))
Expand All @@ -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))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand Down Expand Up @@ -251,7 +251,7 @@ void queryMethodsTest_readsAndCounts() {
}

@Test
void queryMethodsTest_Trader2() {
void queryMethodsTestTrader2() {
List<Trade> trader2Trades = insertTrades("trader2", "SELL", 3);

List<Trade> trader2TradesRetrieved = this.tradeRepository.findByTraderId("trader2");
Expand Down Expand Up @@ -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);
Expand All @@ -354,7 +354,7 @@ void queryMethodsTest_CustomSort() {
}

@Test
void queryMethodsTest_Wildcards() {
void queryMethodsTestWildcards() {
insertTrades("trader1", "BUY", 3);

this.tradeRepository
Expand All @@ -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);
Expand All @@ -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);
Expand Down Expand Up @@ -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");
Expand All @@ -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");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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");
Expand All @@ -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());
Expand All @@ -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;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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);

Expand All @@ -223,7 +223,7 @@ void testSubscribe_AndManualAck()
}

@Test
void testSubscribe_AndManualNack()
void testSubscribeAndManualNack()
throws InterruptedException, ExecutionException, TimeoutException {
this.pubSubSubscriberTemplate.subscribe("sub1", this.consumer);

Expand All @@ -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);
Expand Down Expand Up @@ -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);
Expand Down Expand Up @@ -325,7 +325,7 @@ void destroyingBeanClosesSubscriberStub() {
}

@Test
void testPull_AndManualAck()
void testPullAndManualAck()
throws InterruptedException, ExecutionException, TimeoutException {

List<AcknowledgeablePubsubMessage> result = this.pubSubSubscriberTemplate.pull("sub2", 1, true);
Expand Down Expand Up @@ -353,7 +353,7 @@ void testPull_AndManualAck()
}

@Test
void testPull_AndManualNack()
void testPullAndManualNack()
throws InterruptedException, ExecutionException, TimeoutException {
List<AcknowledgeablePubsubMessage> result = this.pubSubSubscriberTemplate.pull("sub2", 1, true);

Expand All @@ -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);
Expand Down Expand Up @@ -409,7 +409,7 @@ void testPull_AndManualMultiSubscriptionAck()
}

@Test
void testPullAsync_AndManualAck()
void testPullAsyncAndManualAck()
throws InterruptedException, ExecutionException, TimeoutException {

CompletableFuture<List<AcknowledgeablePubsubMessage>> asyncResult =
Expand Down Expand Up @@ -455,7 +455,7 @@ void testPullAndAck() {
}

@Test
void testPullAndAck_NoMessages() {
void testPullAndAckNoMessages() {
when(this.pullCallable.call(any(PullRequest.class)))
.thenReturn(PullResponse.newBuilder().build());

Expand Down Expand Up @@ -484,7 +484,7 @@ void testPullAndAckAsync()
}

@Test
void testPullAndAckAsync_NoMessages()
void testPullAndAckAsyncNoMessages()
throws InterruptedException, ExecutionException, TimeoutException {
when(this.pullApiFuture.get()).thenReturn(PullResponse.newBuilder().build());

Expand Down Expand Up @@ -542,7 +542,7 @@ void testPullNext() {
}

@Test
void testPullNext_NoMessages() {
void testPullNextNoMessages() {
when(this.pullCallable.call(any(PullRequest.class)))
.thenReturn(PullResponse.newBuilder().build());

Expand Down Expand Up @@ -570,7 +570,7 @@ void testPullNextAsync()
}

@Test
void testPullNextAsync_NoMessages()
void testPullNextAsyncNoMessages()
throws InterruptedException, ExecutionException, TimeoutException {
when(this.pullApiFuture.get()).thenReturn(PullResponse.newBuilder().build());

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ void testAckModeAutoAck_neitherAcksNorNacksWhenMessageProcessingFails(CapturedOu
}

@Test
void testSetHealthRegistry_Success() {
void testSetHealthRegistrySuccess() {

setupSubscribeAndConvert();
HealthTrackerRegistry healthTrackerRegistry = mock(HealthTrackerRegistry.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,7 @@ void testCreateSubscriber_invalidMinDurationPerAckExtension_throwsException() {
assertThatThrownBy(
() -> factory.createSubscriber(
"defaultSubscription",
(message, consumer) -> { }
(message, consumer) -> {}
))
.isExactlyInstanceOf(IllegalArgumentException.class);
}
Expand All @@ -419,7 +419,7 @@ void testCreateSubscriber_invalidMaxDurationPerAckExtension_throwsException() {
assertThatThrownBy(
() -> factory.createSubscriber(
"defaultSubscription",
(message, consumer) -> { }
(message, consumer) -> {}
))
.isExactlyInstanceOf(IllegalArgumentException.class);
}
Expand All @@ -440,7 +440,7 @@ void testCreateSubscriber_invalidDurationPerAckExtensions_throwsException() {
assertThatThrownBy(
() -> factory.createSubscriber(
"defaultSubscription",
(message, consumer) -> { }
(message, consumer) -> {}
))
.isExactlyInstanceOf(IllegalArgumentException.class);
}
Expand Down
2 changes: 1 addition & 1 deletion spring-cloud-gcp-samples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

<!-- Checkstyle versions. Keep in sync with ../pom.xml -->
<maven-checkstyle-plugin.version>3.5.0</maven-checkstyle-plugin.version>
<checkstyle-rules.version>10.0</checkstyle-rules.version>
<checkstyle-rules.version>10.21.0</checkstyle-rules.version>

<!-- App engine plugin version, used to deploy sample apps -->
<app-engine-maven-plugin.version>2.8.1</app-engine-maven-plugin.version>
Expand Down

0 comments on commit 073a30f

Please sign in to comment.