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 b57ac52 Small refactoring. b57ac52 is described below commit b57ac52b7c57581d81da14cf8f7a2471fc8dd02e Author: Gary Gregory <garydgreg...@gmail.com> AuthorDate: Fri Jun 26 11:36:27 2020 -0400 Small refactoring. --- .../org/apache/commons/text/StringSubstitutorTest.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/test/java/org/apache/commons/text/StringSubstitutorTest.java b/src/test/java/org/apache/commons/text/StringSubstitutorTest.java index 85d19da..0a37935 100644 --- a/src/test/java/org/apache/commons/text/StringSubstitutorTest.java +++ b/src/test/java/org/apache/commons/text/StringSubstitutorTest.java @@ -51,10 +51,10 @@ public class StringSubstitutorTest { protected Map<String, String> values; protected void doTestNoReplace(final String replaceTemplate) throws IOException { - doTestNoReplace(replaceTemplate, new StringSubstitutor(values)); + doTestNoReplace(new StringSubstitutor(values), replaceTemplate); } - protected void doTestNoReplace(final String replaceTemplate, final StringSubstitutor substitutor) + protected void doTestNoReplace(final StringSubstitutor substitutor, final String replaceTemplate) throws IOException { if (replaceTemplate == null) { assertNull(replace(substitutor, (String) null)); @@ -514,6 +514,11 @@ public class StringSubstitutorTest { doTestReplace("The quick brown fox jumps over the lazy dog.", "The ${animal} jumps over the ${target}.", true); } + @Test + public void testReplaceSimplest() throws IOException { + doTestReplace("quick brown fox", "${animal}", false); + } + /** * Tests simple key replace. */ @@ -547,11 +552,6 @@ public class StringSubstitutorTest { } @Test - public void testReplaceSimplest() throws IOException { - doTestReplace("quick brown fox", "${animal}", false); - } - - @Test public void testReplaceTakingCharSequenceReturningNull() { final StringSubstitutor strSubstitutor = new StringSubstitutor((StringLookup) null);