Merge branch '6.1.x'
This commit is contained in:
commit
3b87c87a33
|
|
@ -50,7 +50,7 @@ public class CheckstyleConventions {
|
|||
project.getPlugins().apply(CheckstylePlugin.class);
|
||||
project.getTasks().withType(Checkstyle.class).forEach(checkstyle -> checkstyle.getMaxHeapSize().set("1g"));
|
||||
CheckstyleExtension checkstyle = project.getExtensions().getByType(CheckstyleExtension.class);
|
||||
checkstyle.setToolVersion("10.13.0");
|
||||
checkstyle.setToolVersion("10.14.1");
|
||||
checkstyle.getConfigDirectory().set(project.getRootProject().file("src/checkstyle"));
|
||||
String version = SpringJavaFormatPlugin.class.getPackage().getImplementationVersion();
|
||||
DependencySet checkstyleDependencies = project.getConfigurations().getByName("checkstyle").getDependencies();
|
||||
|
|
|
|||
|
|
@ -7,27 +7,27 @@ javaPlatform {
|
|||
}
|
||||
|
||||
dependencies {
|
||||
api(platform("com.fasterxml.jackson:jackson-bom:2.15.3"))
|
||||
api(platform("io.micrometer:micrometer-bom:1.12.3"))
|
||||
api(platform("com.fasterxml.jackson:jackson-bom:2.15.4"))
|
||||
api(platform("io.micrometer:micrometer-bom:1.12.4"))
|
||||
api(platform("io.netty:netty-bom:4.1.107.Final"))
|
||||
api(platform("io.netty:netty5-bom:5.0.0.Alpha5"))
|
||||
api(platform("io.projectreactor:reactor-bom:2023.0.3"))
|
||||
api(platform("io.projectreactor:reactor-bom:2023.0.4"))
|
||||
api(platform("io.rsocket:rsocket-bom:1.1.3"))
|
||||
api(platform("org.apache.groovy:groovy-bom:4.0.18"))
|
||||
api(platform("org.apache.groovy:groovy-bom:4.0.19"))
|
||||
api(platform("org.apache.logging.log4j:log4j-bom:2.21.1"))
|
||||
api(platform("org.assertj:assertj-bom:3.25.3"))
|
||||
api(platform("org.eclipse.jetty:jetty-bom:12.0.6"))
|
||||
api(platform("org.eclipse.jetty.ee10:jetty-ee10-bom:12.0.6"))
|
||||
api(platform("org.eclipse.jetty:jetty-bom:12.0.7"))
|
||||
api(platform("org.eclipse.jetty.ee10:jetty-ee10-bom:12.0.7"))
|
||||
api(platform("org.jetbrains.kotlinx:kotlinx-coroutines-bom:1.7.3"))
|
||||
api(platform("org.jetbrains.kotlinx:kotlinx-serialization-bom:1.6.0"))
|
||||
api(platform("org.junit:junit-bom:5.10.2"))
|
||||
api(platform("org.mockito:mockito-bom:5.10.0"))
|
||||
api(platform("org.mockito:mockito-bom:5.11.0"))
|
||||
|
||||
constraints {
|
||||
api("com.fasterxml:aalto-xml:1.3.2")
|
||||
api("com.fasterxml.woodstox:woodstox-core:6.5.1")
|
||||
api("com.github.ben-manes.caffeine:caffeine:3.1.8")
|
||||
api("com.github.librepdf:openpdf:1.3.41")
|
||||
api("com.github.librepdf:openpdf:1.3.42")
|
||||
api("com.google.code.findbugs:findbugs:3.0.1")
|
||||
api("com.google.code.findbugs:jsr305:3.0.2")
|
||||
api("com.google.code.gson:gson:2.10.1")
|
||||
|
|
@ -102,19 +102,19 @@ dependencies {
|
|||
api("org.apache.httpcomponents.client5:httpclient5:5.3.1")
|
||||
api("org.apache.httpcomponents.core5:httpcore5-reactive:5.2.4")
|
||||
api("org.apache.poi:poi-ooxml:5.2.5")
|
||||
api("org.apache.tomcat.embed:tomcat-embed-core:10.1.18")
|
||||
api("org.apache.tomcat.embed:tomcat-embed-websocket:10.1.18")
|
||||
api("org.apache.tomcat:tomcat-util:10.1.18")
|
||||
api("org.apache.tomcat:tomcat-websocket:10.1.18")
|
||||
api("org.aspectj:aspectjrt:1.9.21")
|
||||
api("org.aspectj:aspectjtools:1.9.21")
|
||||
api("org.aspectj:aspectjweaver:1.9.21")
|
||||
api("org.apache.tomcat.embed:tomcat-embed-core:10.1.19")
|
||||
api("org.apache.tomcat.embed:tomcat-embed-websocket:10.1.19")
|
||||
api("org.apache.tomcat:tomcat-util:10.1.19")
|
||||
api("org.apache.tomcat:tomcat-websocket:10.1.19")
|
||||
api("org.aspectj:aspectjrt:1.9.21.1")
|
||||
api("org.aspectj:aspectjtools:1.9.21.1")
|
||||
api("org.aspectj:aspectjweaver:1.9.21.1")
|
||||
api("org.awaitility:awaitility:4.2.0")
|
||||
api("org.bouncycastle:bcpkix-jdk18on:1.72")
|
||||
api("org.codehaus.jettison:jettison:1.5.4")
|
||||
api("org.crac:crac:1.4.0")
|
||||
api("org.dom4j:dom4j:2.1.4")
|
||||
api("org.eclipse.jetty:jetty-reactive-httpclient:4.0.2")
|
||||
api("org.eclipse.jetty:jetty-reactive-httpclient:4.0.3")
|
||||
api("org.eclipse.persistence:org.eclipse.persistence.jpa:3.0.4")
|
||||
api("org.eclipse:yasson:2.0.4")
|
||||
api("org.ehcache:ehcache:3.10.8")
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
|
|||
class ModuleResourceTests {
|
||||
|
||||
private static final String existingPath = "java/beans/Introspector.class";
|
||||
|
||||
private static final String nonExistingPath = "org/example/NonExistingClass.class";
|
||||
|
||||
|
||||
|
|
@ -48,20 +49,10 @@ class ModuleResourceTests {
|
|||
ModuleResource mr = new ModuleResource(Introspector.class.getModule(), existingPath);
|
||||
assertExistingResource(mr);
|
||||
assertThat(mr.getDescription()).startsWith("module resource").contains(mr.getModule().getName(), mr.getPath());
|
||||
System.err.println(mr.getDescription());
|
||||
|
||||
assertThat(mr.getContentAsByteArray()).isEqualTo(cpr.getContentAsByteArray());
|
||||
assertThat(mr.contentLength()).isEqualTo(cpr.contentLength());
|
||||
}
|
||||
|
||||
private static void assertExistingResource(Resource resource) {
|
||||
assertThat(resource.exists()).isTrue();
|
||||
assertThat(resource.isReadable()).isTrue();
|
||||
assertThat(resource.isOpen()).isFalse();
|
||||
assertThat(resource.isFile()).isFalse();
|
||||
assertThat(resource.getFilename()).isEqualTo("Introspector.class");
|
||||
}
|
||||
|
||||
@Test
|
||||
void nonExistingResource() {
|
||||
ModuleResource mr = new ModuleResource(Introspector.class.getModule(), nonExistingPath);
|
||||
|
|
@ -81,6 +72,7 @@ class ModuleResourceTests {
|
|||
Resource resource1 = new ModuleResource(Introspector.class.getModule(), existingPath);
|
||||
Resource resource2 = new ModuleResource(Introspector.class.getModule(), existingPath);
|
||||
Resource resource3 = new ModuleResource(Introspector.class.getModule(), nonExistingPath);
|
||||
|
||||
assertThat(resource1).isEqualTo(resource1);
|
||||
assertThat(resource1).isEqualTo(resource2);
|
||||
assertThat(resource2).isEqualTo(resource1);
|
||||
|
|
@ -89,4 +81,13 @@ class ModuleResourceTests {
|
|||
assertThat(resource1).doesNotHaveSameHashCodeAs(resource3);
|
||||
}
|
||||
|
||||
|
||||
private static void assertExistingResource(Resource resource) {
|
||||
assertThat(resource.exists()).isTrue();
|
||||
assertThat(resource.isReadable()).isTrue();
|
||||
assertThat(resource.isOpen()).isFalse();
|
||||
assertThat(resource.isFile()).isFalse();
|
||||
assertThat(resource.getFilename()).isEqualTo("Introspector.class");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
* Copyright 2002-2024 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
|
@ -51,14 +51,14 @@ import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
|
|||
*/
|
||||
class PathMatchingResourcePatternResolverTests {
|
||||
|
||||
private static final String[] CLASSES_IN_CORE_IO_SUPPORT = { "EncodedResource.class",
|
||||
private static final String[] CLASSES_IN_CORE_IO_SUPPORT = {"EncodedResource.class",
|
||||
"LocalizedResourceHelper.class", "PathMatchingResourcePatternResolver.class", "PropertiesLoaderSupport.class",
|
||||
"PropertiesLoaderUtils.class", "ResourceArrayPropertyEditor.class", "ResourcePatternResolver.class",
|
||||
"ResourcePatternUtils.class", "SpringFactoriesLoader.class" };
|
||||
"ResourcePatternUtils.class", "SpringFactoriesLoader.class"};
|
||||
|
||||
private static final String[] TEST_CLASSES_IN_CORE_IO_SUPPORT = { "PathMatchingResourcePatternResolverTests.class" };
|
||||
private static final String[] TEST_CLASSES_IN_CORE_IO_SUPPORT = {"PathMatchingResourcePatternResolverTests.class"};
|
||||
|
||||
private static final String[] CLASSES_IN_REACTOR_UTIL_ANNOTATION = { "NonNull.class", "NonNullApi.class", "Nullable.class" };
|
||||
private static final String[] CLASSES_IN_REACTOR_UTIL_ANNOTATION = {"NonNull.class", "NonNullApi.class", "Nullable.class"};
|
||||
|
||||
|
||||
private PathMatchingResourcePatternResolver resolver = new PathMatchingResourcePatternResolver();
|
||||
|
|
@ -329,8 +329,8 @@ class PathMatchingResourcePatternResolverTests {
|
|||
}
|
||||
|
||||
private String getPath(Resource resource) {
|
||||
// Tests fail if we use resouce.getURL().getPath(). They would also fail on Mac OS when
|
||||
// using resouce.getURI().getPath() if the resource paths are not Unicode normalized.
|
||||
// Tests fail if we use resource.getURL().getPath(). They would also fail on macOS when
|
||||
// using resource.getURI().getPath() if the resource paths are not Unicode normalized.
|
||||
//
|
||||
// On the JVM, all tests should pass when using resouce.getFile().getPath(); however,
|
||||
// we use FileSystemResource#getPath since this test class is sometimes run within a
|
||||
|
|
|
|||
Loading…
Reference in New Issue