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 da87e5c More tests.
da87e5c is described below
commit da87e5cc6bea68fd9694cc9f59a8b78cad4eb4b1
Author: Gary Gregory <[email protected]>
AuthorDate: Mon Jul 6 18:22:51 2020 -0400
More tests.
---
src/test/java/org/apache/commons/text/StringSubstitutorTest.java | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/src/test/java/org/apache/commons/text/StringSubstitutorTest.java
b/src/test/java/org/apache/commons/text/StringSubstitutorTest.java
index d2cdec4..bbf7530 100644
--- a/src/test/java/org/apache/commons/text/StringSubstitutorTest.java
+++ b/src/test/java/org/apache/commons/text/StringSubstitutorTest.java
@@ -815,6 +815,7 @@ public class StringSubstitutorTest {
*/
@Test
public void testReplaceVariablesCount1Escaping2To1() throws IOException {
+ doReplace("${a}", "$${a}", false);
doReplace("${animal}", "$${animal}", false);
}
@@ -823,6 +824,7 @@ public class StringSubstitutorTest {
*/
@Test
public void testReplaceVariablesCount1Escaping3To2() throws IOException {
+ doReplace("$${a}", "$$${a}", false);
doReplace("$${animal}", "$$${animal}", false);
}
@@ -831,6 +833,7 @@ public class StringSubstitutorTest {
*/
@Test
public void testReplaceVariablesCount1Escaping4To3() throws IOException {
+ doReplace("$$${a}", "$$$${a}", false);
doReplace("$$${animal}", "$$$${animal}", false);
}
@@ -839,6 +842,7 @@ public class StringSubstitutorTest {
*/
@Test
public void testReplaceVariablesCount1Escaping5To4() throws IOException {
+ doReplace("$$$${a}", "$$$$${a}", false);
doReplace("$$$${animal}", "$$$$${animal}", false);
}
@@ -924,6 +928,9 @@ public class StringSubstitutorTest {
doNotReplace("$${a");
doNotReplace("$$${");
doNotReplace("$$${a");
+ doNotReplace("$${${a");
+ //
+ doReplace("$${1", "$${${a}", false);
}
/**