PropertySourcesPlaceholderConfigurer's "ignoreUnresolvablePlaceholders" setting reliably applies to nested placeholders as well

Issue: SPR-10549
This commit is contained in:
Juergen Hoeller
2013-07-31 17:50:44 +02:00
parent 803779d160
commit 127b91fd4f
8 changed files with 131 additions and 56 deletions
@@ -1,5 +1,5 @@
/*
* Copyright 2002-2012 the original author or authors.
* Copyright 2002-2013 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.
@@ -30,8 +30,6 @@ import static org.hamcrest.Matchers.*;
import static org.junit.Assert.*;
/**
* Unit tests for {@link PropertySourcesPropertyResolver}.
*
* @author Chris Beams
* @since 3.1
*/
@@ -387,8 +385,8 @@ public class PropertySourcesPropertyResolverTests {
try {
pr.getProperty("pL");
}
catch (StackOverflowError ex) {
// no explicit handling for cyclic references for now
catch (IllegalArgumentException ex) {
assertTrue(ex.getMessage().toLowerCase().contains("circular"));
}
}