This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-text.git
The following commit(s) were added to refs/heads/master by this push:
new 507b214 More tests.
507b214 is described below
commit 507b2141f13c8e2a9c73f6dd80187576595ec804
Author: Gary Gregory <[email protected]>
AuthorDate: Wed Jul 1 13:27:19 2020 -0400
More tests.
---
src/test/java/org/apache/commons/text/StringSubstitutorTest.java | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/test/java/org/apache/commons/text/StringSubstitutorTest.java
b/src/test/java/org/apache/commons/text/StringSubstitutorTest.java
index 2224259..6382845 100644
--- a/src/test/java/org/apache/commons/text/StringSubstitutorTest.java
+++ b/src/test/java/org/apache/commons/text/StringSubstitutorTest.java
@@ -252,6 +252,12 @@ public class StringSubstitutorTest {
public void testReplaceComplexEscaping() throws IOException {
doTestReplace("The ${quick brown fox} jumps over the lazy dog.", "The
$${${animal}} jumps over the ${target}.",
true);
+ doTestReplace("${${animal}}", "$${$${animal}}", false);
+ doTestReplace(".${${animal}}", ".$${$${animal}}", false);
+ doTestReplace("${${animal}}.", "$${$${animal}}.", false);
+ doTestReplace(".${${animal}}.", ".$${$${animal}}.", false);
+ doTestReplace("The ${${animal}} jumps over the lazy dog.", "The
$${$${animal}} jumps over the ${target}.",
+ true);
doTestReplace("The ${quick brown fox} jumps over the lazy dog.
${1234567890}.",
"The $${${animal}} jumps over the ${target}.
$${${undefined.number:-1234567890}}.", true);
}