From 6c08d9399239f421d0a19fc838e3d9d623d7e2e0 Mon Sep 17 00:00:00 2001 From: Juergen Hoeller Date: Thu, 23 May 2024 17:07:55 +0200 Subject: [PATCH] Polishing --- .../cache/annotation/EnableCachingIntegrationTests.java | 2 +- .../core/env/EnvironmentSystemIntegrationTests.java | 3 +-- .../EnableTransactionManagementIntegrationTests.java | 5 ++--- .../cache/config/annotation-jcache-aspectj.xml | 3 +-- .../scheduling/aspectj/annotationDrivenContext.xml | 6 ++---- 5 files changed, 7 insertions(+), 12 deletions(-) diff --git a/integration-tests/src/test/java/org/springframework/cache/annotation/EnableCachingIntegrationTests.java b/integration-tests/src/test/java/org/springframework/cache/annotation/EnableCachingIntegrationTests.java index e024478d1e1b..104ca11ca1e4 100644 --- a/integration-tests/src/test/java/org/springframework/cache/annotation/EnableCachingIntegrationTests.java +++ b/integration-tests/src/test/java/org/springframework/cache/annotation/EnableCachingIntegrationTests.java @@ -62,7 +62,7 @@ void repositoryUsesAspectJAdviceMode() { // attempt was made to look up the AJ aspect. It's due to classpath issues // in integration-tests that it's not found. assertThatException().isThrownBy(ctx::refresh) - .withMessageContaining("AspectJCachingConfiguration"); + .withMessageContaining("AspectJCachingConfiguration"); } diff --git a/integration-tests/src/test/java/org/springframework/core/env/EnvironmentSystemIntegrationTests.java b/integration-tests/src/test/java/org/springframework/core/env/EnvironmentSystemIntegrationTests.java index f8ac5f80031f..824099b4c2c6 100644 --- a/integration-tests/src/test/java/org/springframework/core/env/EnvironmentSystemIntegrationTests.java +++ b/integration-tests/src/test/java/org/springframework/core/env/EnvironmentSystemIntegrationTests.java @@ -541,8 +541,7 @@ void abstractApplicationContextValidatesRequiredPropertiesOnRefresh() { { ConfigurableApplicationContext ctx = new AnnotationConfigApplicationContext(); ctx.getEnvironment().setRequiredProperties("foo", "bar"); - assertThatExceptionOfType(MissingRequiredPropertiesException.class).isThrownBy( - ctx::refresh); + assertThatExceptionOfType(MissingRequiredPropertiesException.class).isThrownBy(ctx::refresh); } { diff --git a/integration-tests/src/test/java/org/springframework/transaction/annotation/EnableTransactionManagementIntegrationTests.java b/integration-tests/src/test/java/org/springframework/transaction/annotation/EnableTransactionManagementIntegrationTests.java index 9ab1fd401853..9b7eef5a0961 100644 --- a/integration-tests/src/test/java/org/springframework/transaction/annotation/EnableTransactionManagementIntegrationTests.java +++ b/integration-tests/src/test/java/org/springframework/transaction/annotation/EnableTransactionManagementIntegrationTests.java @@ -97,9 +97,8 @@ void repositoryUsesAspectJAdviceMode() { // this test is a bit fragile, but gets the job done, proving that an // attempt was made to look up the AJ aspect. It's due to classpath issues // in integration-tests that it's not found. - assertThatException() - .isThrownBy(ctx::refresh) - .withMessageContaining("AspectJJtaTransactionManagementConfiguration"); + assertThatException().isThrownBy(ctx::refresh) + .withMessageContaining("AspectJJtaTransactionManagementConfiguration"); } @Test diff --git a/spring-aspects/src/test/resources/org/springframework/cache/config/annotation-jcache-aspectj.xml b/spring-aspects/src/test/resources/org/springframework/cache/config/annotation-jcache-aspectj.xml index 54ddbfd44a7b..9366abc646ee 100644 --- a/spring-aspects/src/test/resources/org/springframework/cache/config/annotation-jcache-aspectj.xml +++ b/spring-aspects/src/test/resources/org/springframework/cache/config/annotation-jcache-aspectj.xml @@ -24,8 +24,7 @@ - + diff --git a/spring-aspects/src/test/resources/org/springframework/scheduling/aspectj/annotationDrivenContext.xml b/spring-aspects/src/test/resources/org/springframework/scheduling/aspectj/annotationDrivenContext.xml index 61d1d3a8e9bf..2bc3dc1d113d 100644 --- a/spring-aspects/src/test/resources/org/springframework/scheduling/aspectj/annotationDrivenContext.xml +++ b/spring-aspects/src/test/resources/org/springframework/scheduling/aspectj/annotationDrivenContext.xml @@ -7,12 +7,10 @@ http://www.springframework.org/schema/task https://www.springframework.org/schema/task/spring-task.xsd"> - + - +