From 66ed4fe519d5ddc14d36cae686f397cea101ceac Mon Sep 17 00:00:00 2001 From: Moritz Halbritter Date: Wed, 8 Nov 2023 09:49:35 +0100 Subject: [PATCH] Remove system property dependency from MockBeanContextCachingTests Now this test can be run regardless of the 'spring.test.context.cache.maxSize' system property value. See gh-38236 --- .../boot/test/mock/mockito/MockBeanContextCachingTests.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spring-boot-project/spring-boot-test/src/test/java/org/springframework/boot/test/mock/mockito/MockBeanContextCachingTests.java b/spring-boot-project/spring-boot-test/src/test/java/org/springframework/boot/test/mock/mockito/MockBeanContextCachingTests.java index 50b1db33823..59dd0c1e38b 100644 --- a/spring-boot-project/spring-boot-test/src/test/java/org/springframework/boot/test/mock/mockito/MockBeanContextCachingTests.java +++ b/spring-boot-project/spring-boot-test/src/test/java/org/springframework/boot/test/mock/mockito/MockBeanContextCachingTests.java @@ -45,7 +45,7 @@ import static org.mockito.Mockito.mock; */ class MockBeanContextCachingTests { - private final DefaultContextCache contextCache = new DefaultContextCache(); + private final DefaultContextCache contextCache = new DefaultContextCache(2); private final DefaultCacheAwareContextLoaderDelegate delegate = new DefaultCacheAwareContextLoaderDelegate( this.contextCache);