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

Issue: SPR-10549
(cherry picked from commit 127b91f)
This commit is contained in:
Juergen Hoeller
2013-07-31 17:50:44 +02:00
parent 2f8dfb3e52
commit b40263e06b
8 changed files with 132 additions and 57 deletions

View File

@@ -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"));
}
}