diff --git a/core/spring-boot/src/main/java/org/springframework/boot/context/config/Profiles.java b/core/spring-boot/src/main/java/org/springframework/boot/context/config/Profiles.java index 825d914fde1..d99ddd86565 100644 --- a/core/spring-boot/src/main/java/org/springframework/boot/context/config/Profiles.java +++ b/core/spring-boot/src/main/java/org/springframework/boot/context/config/Profiles.java @@ -106,7 +106,7 @@ public class Profiles implements Iterable { ? Collections.emptySet() : StringUtils.commaDelimitedListToSet(StringUtils.trimAllWhitespace(environmentPropertyValue)); validator.validate(environmentPropertyProfiles, - () -> "Invalid profile property value found in Envronment under '%s'".formatted(type.getName())); + () -> "Invalid profile property value found in Environment under '%s'".formatted(type.getName())); Set environmentProfiles = new LinkedHashSet<>(Arrays.asList(type.get(environment))); BindResult> boundProfiles = binder.bind(type.getName(), STRING_SET, validator); if (hasProgrammaticallySetProfiles(type, environmentPropertyValue, environmentPropertyProfiles, diff --git a/core/spring-boot/src/test/java/org/springframework/boot/context/config/ProfilesTests.java b/core/spring-boot/src/test/java/org/springframework/boot/context/config/ProfilesTests.java index f7d2900b8d8..40d213b26b3 100644 --- a/core/spring-boot/src/test/java/org/springframework/boot/context/config/ProfilesTests.java +++ b/core/spring-boot/src/test/java/org/springframework/boot/context/config/ProfilesTests.java @@ -453,7 +453,7 @@ class ProfilesTests { environment.setProperty("spring.profiles.active", "fa!l"); Binder binder = new Binder(); assertThatIllegalStateException().isThrownBy(() -> new Profiles(environment, binder, null)) - .withMessage("Invalid profile property value found in Envronment under 'spring.profiles.active'"); + .withMessage("Invalid profile property value found in Environment under 'spring.profiles.active'"); } @Test