use of org.springframework.core.env.EnumerablePropertySource in project spring-framework by spring-projects.
the class InlinedPropertiesTestPropertySourceTests method propertyNameOrderingIsPreservedInEnvironment.
@Test
@SuppressWarnings("rawtypes")
public void propertyNameOrderingIsPreservedInEnvironment() {
final String[] expectedPropertyNames = new String[] { "foo", "baz", "enigma", "x.y.z", "server.url", "key.value.1", "key.value.2", "key.value.3" };
EnumerablePropertySource eps = (EnumerablePropertySource) env.getPropertySources().get(INLINED_PROPERTIES_PROPERTY_SOURCE_NAME);
assertArrayEquals(expectedPropertyNames, eps.getPropertyNames());
}
Aggregations