Update Javadoc for active profile ordering

Following gh-26004, the registration order of active profiles in
@⁠ActiveProfiles is preserved; however, the Javadoc in
MergedContextConfiguration and WebMergedContextConfiguration still
described the old sorting behavior, which is misleading since profile
order is part of the context cache key (equals/hashCode).

This commit updates the Javadoc to document the status quo.

Closes gh-36950

Signed-off-by: Alexis SEGURA <alex.segura06@gmail.com>
This commit is contained in:
Alexis SEGURA
2026-07-25 11:04:11 +03:00
committed by Sam Brannen
parent b5de644cbb
commit e255ccca7d
2 changed files with 12 additions and 12 deletions
@@ -190,8 +190,8 @@ public class MergedContextConfiguration implements Serializable {
* or {@code propertySourceProperties} an empty array will be stored instead.
* If a {@code null} value is supplied for the
* {@code contextInitializerClasses} an empty set will be stored instead.
* Furthermore, active profiles will be sorted, and duplicate profiles
* will be removed.
* Furthermore, duplicate active profiles will be removed while preserving
* registration order.
* @param testClass the test class for which the configuration was merged
* @param locations the merged context resource locations
* @param classes the merged annotated classes
@@ -229,8 +229,8 @@ public class MergedContextConfiguration implements Serializable {
* or {@code propertySourceProperties} an empty array will be stored instead.
* If a {@code null} value is supplied for {@code contextInitializerClasses}
* or {@code contextCustomizers}, an empty set will be stored instead.
* Furthermore, active profiles will be sorted, and duplicate profiles
* will be removed.
* Furthermore, duplicate active profiles will be removed while preserving
* registration order.
* @param testClass the test class for which the configuration was merged
* @param locations the merged context resource locations
* @param classes the merged annotated classes
@@ -268,8 +268,8 @@ public class MergedContextConfiguration implements Serializable {
* {@code activeProfiles}, or {@code propertySourceProperties} an empty array
* will be stored instead. If a {@code null} value is supplied for
* {@code contextInitializerClasses} or {@code contextCustomizers}, an empty
* set will be stored instead. Furthermore, active profiles will be sorted,
* and duplicate profiles will be removed.
* set will be stored instead. Furthermore, duplicate active profiles
* will be removed while preserving registration order.
* @param testClass the test class for which the configuration was merged
* @param locations the merged context resource locations
* @param classes the merged annotated classes
@@ -87,8 +87,8 @@ public class WebMergedContextConfiguration extends MergedContextConfiguration {
* If a {@code null} value is supplied for the
* {@code contextInitializerClasses} an empty set will be stored instead.
* If an <em>empty</em> value is supplied for the {@code resourceBasePath}
* an empty string will be used. Furthermore, active profiles will be sorted,
* and duplicate profiles will be removed.
* an empty string will be used. Furthermore, duplicate active profiles
* will be removed while preserving registration order.
* @param testClass the test class for which the configuration was merged
* @param locations the merged resource locations
* @param classes the merged annotated classes
@@ -125,8 +125,8 @@ public class WebMergedContextConfiguration extends MergedContextConfiguration {
* If a {@code null} value is supplied for {@code contextInitializerClasses}
* or {@code contextCustomizers}, an empty set will be stored instead.
* If an <em>empty</em> value is supplied for the {@code resourceBasePath}
* an empty string will be used. Furthermore, active profiles will be sorted,
* and duplicate profiles will be removed.
* an empty string will be used. Furthermore, duplicate active profiles
* will be removed while preserving registration order.
* @param testClass the test class for which the configuration was merged
* @param locations the merged context resource locations
* @param classes the merged annotated classes
@@ -164,8 +164,8 @@ public class WebMergedContextConfiguration extends MergedContextConfiguration {
* {@code activeProfiles}, or {@code propertySourceProperties} an empty array
* will be stored instead. If a {@code null} value is supplied for
* {@code contextInitializerClasses} or {@code contextCustomizers}, an empty
* set will be stored instead. Furthermore, active profiles will be sorted,
* and duplicate profiles will be removed.
* set will be stored instead. Furthermore, duplicate active profiles
* will be removed while preserving registration order.
* @param testClass the test class for which the configuration was merged
* @param locations the merged context resource locations
* @param classes the merged annotated classes