mirror of
https://github.com/spring-projects/spring-framework
synced 2026-06-08 17:33:33 +00:00
Consistently use American English spelling
Since the Spring Framework uses American English spelling, this commit
updates Javadoc and the reference manual to ensure consistency in that
regard. However, there are two exceptions to this rule that arise due
to their use within a technical context.
- We use "cancelled/cancelling" instead of "canceled/canceling" in
numerous places (including error messages).
- We use "implementor" instead of "implementer".
Closes gh-36470
(cherry picked from commit 17699103dc)
This commit is contained in:
+9
-12
@@ -32,7 +32,7 @@ import org.dom4j.io.SAXReader;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import org.springframework.beans.propertyeditors.StringTrimmerEditor;
|
||||
import org.springframework.beans.testfixture.beans.Colour;
|
||||
import org.springframework.beans.testfixture.beans.Color;
|
||||
import org.springframework.beans.testfixture.beans.Pet;
|
||||
import org.springframework.beans.testfixture.beans.TestBean;
|
||||
import org.springframework.validation.BeanPropertyBindingResult;
|
||||
@@ -447,8 +447,8 @@ class CheckboxTagTests extends AbstractFormTagTests {
|
||||
}
|
||||
|
||||
@Test
|
||||
void collectionOfColoursSelected() throws Exception {
|
||||
this.tag.setPath("otherColours");
|
||||
void collectionOfColorsSelected() throws Exception {
|
||||
this.tag.setPath("otherColors");
|
||||
this.tag.setValue("RED");
|
||||
|
||||
int result = this.tag.doStartTag();
|
||||
@@ -464,13 +464,13 @@ class CheckboxTagTests extends AbstractFormTagTests {
|
||||
Element checkboxElement = document.getRootElement().elements().get(0);
|
||||
assertThat(checkboxElement.getName()).isEqualTo("input");
|
||||
assertThat(checkboxElement.attribute("type").getValue()).isEqualTo("checkbox");
|
||||
assertThat(checkboxElement.attribute("name").getValue()).isEqualTo("otherColours");
|
||||
assertThat(checkboxElement.attribute("name").getValue()).isEqualTo("otherColors");
|
||||
assertThat(checkboxElement.attribute("checked").getValue()).isEqualTo("checked");
|
||||
}
|
||||
|
||||
@Test
|
||||
void collectionOfColoursNotSelected() throws Exception {
|
||||
this.tag.setPath("otherColours");
|
||||
void collectionOfColorsNotSelected() throws Exception {
|
||||
this.tag.setPath("otherColors");
|
||||
this.tag.setValue("PURPLE");
|
||||
|
||||
int result = this.tag.doStartTag();
|
||||
@@ -486,7 +486,7 @@ class CheckboxTagTests extends AbstractFormTagTests {
|
||||
Element checkboxElement = document.getRootElement().elements().get(0);
|
||||
assertThat(checkboxElement.getName()).isEqualTo("input");
|
||||
assertThat(checkboxElement.attribute("type").getValue()).isEqualTo("checkbox");
|
||||
assertThat(checkboxElement.attribute("name").getValue()).isEqualTo("otherColours");
|
||||
assertThat(checkboxElement.attribute("name").getValue()).isEqualTo("otherColors");
|
||||
assertThat(checkboxElement.attribute("checked")).isNull();
|
||||
}
|
||||
|
||||
@@ -659,10 +659,7 @@ class CheckboxTagTests extends AbstractFormTagTests {
|
||||
|
||||
@Override
|
||||
protected TestBean createTestBean() {
|
||||
List colours = new ArrayList();
|
||||
colours.add(Colour.BLUE);
|
||||
colours.add(Colour.RED);
|
||||
colours.add(Colour.GREEN);
|
||||
List colors = List.of(Color.BLUE, Color.RED, Color.GREEN);
|
||||
|
||||
List pets = new ArrayList();
|
||||
pets.add(new Pet("Rudiger"));
|
||||
@@ -684,7 +681,7 @@ class CheckboxTagTests extends AbstractFormTagTests {
|
||||
this.bean.setSomeBoolean(Boolean.TRUE);
|
||||
this.bean.setStringArray(new String[] {"bar", "foo"});
|
||||
this.bean.setSomeIntegerArray(new Integer[] {2, 1});
|
||||
this.bean.setOtherColours(colours);
|
||||
this.bean.setOtherColors(colors);
|
||||
this.bean.setPets(pets);
|
||||
this.bean.setSomeList(someList);
|
||||
this.bean.setSomeMap(someMap);
|
||||
|
||||
+3
-6
@@ -35,7 +35,7 @@ import org.dom4j.io.SAXReader;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import org.springframework.beans.propertyeditors.StringTrimmerEditor;
|
||||
import org.springframework.beans.testfixture.beans.Colour;
|
||||
import org.springframework.beans.testfixture.beans.Color;
|
||||
import org.springframework.beans.testfixture.beans.Pet;
|
||||
import org.springframework.beans.testfixture.beans.TestBean;
|
||||
import org.springframework.format.Formatter;
|
||||
@@ -741,10 +741,7 @@ public class CheckboxesTagTests extends AbstractFormTagTests {
|
||||
|
||||
@Override
|
||||
protected TestBean createTestBean() {
|
||||
List colours = new ArrayList();
|
||||
colours.add(Colour.BLUE);
|
||||
colours.add(Colour.RED);
|
||||
colours.add(Colour.GREEN);
|
||||
List colors = List.of(Color.BLUE, Color.RED, Color.GREEN);
|
||||
|
||||
List pets = new ArrayList();
|
||||
pets.add(new Pet("Rudiger"));
|
||||
@@ -763,7 +760,7 @@ public class CheckboxesTagTests extends AbstractFormTagTests {
|
||||
this.bean.setSomeBoolean(Boolean.TRUE);
|
||||
this.bean.setStringArray(new String[] {"bar", "foo"});
|
||||
this.bean.setSomeIntegerArray(new Integer[] {2, 1});
|
||||
this.bean.setOtherColours(colours);
|
||||
this.bean.setOtherColors(colors);
|
||||
this.bean.setPets(pets);
|
||||
this.bean.setSomeSet(someObjects);
|
||||
List list = new ArrayList();
|
||||
|
||||
+2
-2
@@ -27,7 +27,7 @@ import jakarta.servlet.jsp.tagext.Tag;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import org.springframework.beans.propertyeditors.StringArrayPropertyEditor;
|
||||
import org.springframework.beans.testfixture.beans.Colour;
|
||||
import org.springframework.beans.testfixture.beans.Color;
|
||||
import org.springframework.beans.testfixture.beans.TestBean;
|
||||
import org.springframework.lang.Nullable;
|
||||
import org.springframework.util.StringUtils;
|
||||
@@ -482,7 +482,7 @@ class OptionTagTests extends AbstractHtmlElementTagTests {
|
||||
protected void extendRequest(MockHttpServletRequest request) {
|
||||
TestBean bean = new TestBean();
|
||||
bean.setName("foo");
|
||||
bean.setFavouriteColour(Colour.GREEN);
|
||||
bean.setFavouriteColor(Color.GREEN);
|
||||
bean.setStringArray(ARRAY);
|
||||
bean.setSpouse(new TestBean("Sally"));
|
||||
bean.setSomeNumber(Float.valueOf("12.34"));
|
||||
|
||||
+5
-5
@@ -35,7 +35,7 @@ import org.dom4j.io.SAXReader;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import org.springframework.beans.propertyeditors.StringTrimmerEditor;
|
||||
import org.springframework.beans.testfixture.beans.Colour;
|
||||
import org.springframework.beans.testfixture.beans.Color;
|
||||
import org.springframework.beans.testfixture.beans.Pet;
|
||||
import org.springframework.beans.testfixture.beans.TestBean;
|
||||
import org.springframework.validation.BeanPropertyBindingResult;
|
||||
@@ -595,9 +595,9 @@ public class RadioButtonsTagTests extends AbstractFormTagTests {
|
||||
@Override
|
||||
protected TestBean createTestBean() {
|
||||
List colours = new ArrayList();
|
||||
colours.add(Colour.BLUE);
|
||||
colours.add(Colour.RED);
|
||||
colours.add(Colour.GREEN);
|
||||
colours.add(Color.BLUE);
|
||||
colours.add(Color.RED);
|
||||
colours.add(Color.GREEN);
|
||||
|
||||
List pets = new ArrayList();
|
||||
pets.add(new Pet("Rudiger"));
|
||||
@@ -612,7 +612,7 @@ public class RadioButtonsTagTests extends AbstractFormTagTests {
|
||||
this.bean.setSomeBoolean(Boolean.TRUE);
|
||||
this.bean.setStringArray(new String[] {"bar", "foo"});
|
||||
this.bean.setSomeIntegerArray(new Integer[] {2, 1});
|
||||
this.bean.setOtherColours(colours);
|
||||
this.bean.setOtherColors(colours);
|
||||
this.bean.setPets(pets);
|
||||
List list = new ArrayList();
|
||||
list.add("foo");
|
||||
|
||||
Reference in New Issue
Block a user