commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brit...@apache.org
Subject [2/5] [lang] Clarify behavior for chars that are not next to each other in the supplied search CharSequence
Date Thu, 07 May 2015 15:56:30 GMT
Clarify behavior for chars that are not next to each other in the supplied search CharSequence


Project: http://git-wip-us.apache.org/repos/asf/commons-lang/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-lang/commit/636a5148
Tree: http://git-wip-us.apache.org/repos/asf/commons-lang/tree/636a5148
Diff: http://git-wip-us.apache.org/repos/asf/commons-lang/diff/636a5148

Branch: refs/heads/master
Commit: 636a5148405f567310b9fcd4dec131fa1936130c
Parents: adc6bc4
Author: Benedikt Ritter <britter@apache.org>
Authored: Thu May 7 17:48:32 2015 +0200
Committer: Benedikt Ritter <britter@apache.org>
Committed: Thu May 7 17:48:32 2015 +0200

----------------------------------------------------------------------
 src/main/java/org/apache/commons/lang3/StringUtils.java             | 1 +
 .../java/org/apache/commons/lang3/StringUtilsEqualsIndexOfTest.java | 1 +
 2 files changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/commons-lang/blob/636a5148/src/main/java/org/apache/commons/lang3/StringUtils.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/lang3/StringUtils.java b/src/main/java/org/apache/commons/lang3/StringUtils.java
index fcd924c..3f35abb 100644
--- a/src/main/java/org/apache/commons/lang3/StringUtils.java
+++ b/src/main/java/org/apache/commons/lang3/StringUtils.java
@@ -1652,6 +1652,7 @@ public class StringUtils {
      * StringUtils.containsAny(*, "")              = false
      * StringUtils.containsAny("zzabyycdxx", "za") = true
      * StringUtils.containsAny("zzabyycdxx", "by") = true
+     * StringUtils.containsAny("zzabyycdxx", "zy") = true
      * StringUtils.containsAny("aba","z")          = false
      * </pre>
      *

http://git-wip-us.apache.org/repos/asf/commons-lang/blob/636a5148/src/test/java/org/apache/commons/lang3/StringUtilsEqualsIndexOfTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/lang3/StringUtilsEqualsIndexOfTest.java b/src/test/java/org/apache/commons/lang3/StringUtilsEqualsIndexOfTest.java
index edf1e7a..bafb085 100644
--- a/src/test/java/org/apache/commons/lang3/StringUtilsEqualsIndexOfTest.java
+++ b/src/test/java/org/apache/commons/lang3/StringUtilsEqualsIndexOfTest.java
@@ -179,6 +179,7 @@ public class StringUtilsEqualsIndexOfTest  {
         assertFalse(StringUtils.containsAny("zzabyycdxx", ""));
         assertTrue(StringUtils.containsAny("zzabyycdxx", "za"));
         assertTrue(StringUtils.containsAny("zzabyycdxx", "by"));
+        assertTrue(StringUtils.containsAny("zzabyycdxx", "zy"));
         assertFalse(StringUtils.containsAny("ab", "z"));
     }
 


Mime
View raw message