Fix typos
Closes gh-34876 Signed-off-by: Tran Ngoc Nhan <ngocnhan.tran1996@gmail.com>
This commit is contained in:
committed by
rstoyanchev
parent
182d654fa8
commit
3f0892b42c
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
* Copyright 2002-2025 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.
|
||||
@@ -250,7 +250,7 @@ public abstract class ValidationUtils {
|
||||
|
||||
Assert.notNull(errors, "Errors object must not be null");
|
||||
Object value = errors.getFieldValue(field);
|
||||
if (value == null ||!StringUtils.hasText(value.toString())) {
|
||||
if (value == null || !StringUtils.hasText(value.toString())) {
|
||||
errors.rejectValue(field, errorCode, errorArgs, defaultMessage);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2022 the original author or authors.
|
||||
* Copyright 2002-2025 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.
|
||||
@@ -32,7 +32,7 @@ import static org.assertj.core.api.Assertions.assertThat;
|
||||
class AnnotationBackCompatibilityTests {
|
||||
|
||||
@Test
|
||||
void multiplRoutesToMetaAnnotation() {
|
||||
void multipleRoutesToMetaAnnotation() {
|
||||
Class<?> source = WithMetaMetaTestAnnotation1AndMetaTestAnnotation2.class;
|
||||
// Merged annotation chooses lowest depth
|
||||
MergedAnnotation<TestAnnotation> mergedAnnotation = MergedAnnotations.from(source).get(TestAnnotation.class);
|
||||
|
||||
@@ -983,7 +983,7 @@ class MergedAnnotationsTests {
|
||||
}
|
||||
|
||||
@Test
|
||||
void getDirectFromClassgetDirectFromClassMetaMetaAnnotatedClass() {
|
||||
void getDirectFromClassGetDirectFromClassMetaMetaAnnotatedClass() {
|
||||
MergedAnnotation<?> annotation = MergedAnnotations.from(
|
||||
MetaMetaAnnotatedClass.class, SearchStrategy.TYPE_HIERARCHY).get(Component.class);
|
||||
assertThat(annotation.getString("value")).isEqualTo("meta2");
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2020 the original author or authors.
|
||||
* Copyright 2002-2025 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.
|
||||
@@ -46,7 +46,7 @@ class ConverterTests {
|
||||
}
|
||||
|
||||
@Test
|
||||
void andThenCanConvertfromDifferentSourceType() {
|
||||
void andThenCanConvertFromDifferentSourceType() {
|
||||
Converter<String, Integer> length = String::length;
|
||||
assertThat(length.andThen(this.moduloTwo).convert("example")).isEqualTo(1);
|
||||
assertThat(length.andThen(this.addOne).convert("example")).isEqualTo(8);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2024 the original author or authors.
|
||||
* Copyright 2002-2025 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.
|
||||
@@ -491,8 +491,8 @@ class AntPathMatcherTests {
|
||||
assertThat(comparator.compare("/hotels/{hotel}/bookings/{booking}", "/hotels/{hotel}/booking")).isEqualTo(1);
|
||||
|
||||
// SPR-10550
|
||||
assertThat(comparator.compare("/hotels/{hotel}/bookings/{booking}/cutomers/{customer}", "/**")).isEqualTo(-1);
|
||||
assertThat(comparator.compare("/**", "/hotels/{hotel}/bookings/{booking}/cutomers/{customer}")).isEqualTo(1);
|
||||
assertThat(comparator.compare("/hotels/{hotel}/bookings/{booking}/customers/{customer}", "/**")).isEqualTo(-1);
|
||||
assertThat(comparator.compare("/**", "/hotels/{hotel}/bookings/{booking}/customers/{customer}")).isEqualTo(1);
|
||||
assertThat(comparator.compare("/**", "/**")).isEqualTo(0);
|
||||
|
||||
assertThat(comparator.compare("/hotels/{hotel}", "/hotels/*")).isEqualTo(-1);
|
||||
@@ -505,8 +505,8 @@ class AntPathMatcherTests {
|
||||
assertThat(comparator.compare("/hotels/{hotel}", "/hotels/{hotel}.*")).isEqualTo(2);
|
||||
|
||||
// SPR-6741
|
||||
assertThat(comparator.compare("/hotels/{hotel}/bookings/{booking}/cutomers/{customer}", "/hotels/**")).isEqualTo(-1);
|
||||
assertThat(comparator.compare("/hotels/**", "/hotels/{hotel}/bookings/{booking}/cutomers/{customer}")).isEqualTo(1);
|
||||
assertThat(comparator.compare("/hotels/{hotel}/bookings/{booking}/customers/{customer}", "/hotels/**")).isEqualTo(-1);
|
||||
assertThat(comparator.compare("/hotels/**", "/hotels/{hotel}/bookings/{booking}/customers/{customer}")).isEqualTo(1);
|
||||
assertThat(comparator.compare("/hotels/foo/bar/**", "/hotels/{hotel}")).isEqualTo(1);
|
||||
assertThat(comparator.compare("/hotels/{hotel}", "/hotels/foo/bar/**")).isEqualTo(-1);
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
* Copyright 2002-2025 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.
|
||||
@@ -22,7 +22,7 @@ import org.junit.jupiter.api.Test
|
||||
/**
|
||||
* Kotlin tests for [BridgeMethodResolver].
|
||||
*
|
||||
* @author Sebastien Deleuzes
|
||||
* @author Sebastien Deleuze
|
||||
*/
|
||||
class BridgeMethodResolverKotlinTests {
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2024 the original author or authors.
|
||||
* Copyright 2002-2025 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.
|
||||
@@ -103,7 +103,7 @@ class SpringHandlerInstantiatorTests {
|
||||
}
|
||||
|
||||
@Test
|
||||
void applicationContextAwaretypeResolverBuilder() throws JsonProcessingException {
|
||||
void applicationContextAwareTypeResolverBuilder() throws JsonProcessingException {
|
||||
this.objectMapper.writeValueAsString(new Group());
|
||||
assertThat(CustomTypeResolverBuilder.isAutowiredFiledInitialized).isTrue();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user