mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
add test for replace
This commit is contained in:
@@ -5,6 +5,12 @@ import org.junit.Test;
|
|||||||
|
|
||||||
public class CharSequenceUtilTest {
|
public class CharSequenceUtilTest {
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void replace() {
|
||||||
|
String actual = CharSequenceUtil.replace("SSM15930297701BeryAllen", Pattern.compile("[0-9]"), matcher -> "");
|
||||||
|
Assert.assertEquals("SSMBeryAllen", actual);
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void addPrefixIfNotTest(){
|
public void addPrefixIfNotTest(){
|
||||||
String str = "hutool";
|
String str = "hutool";
|
||||||
|
Reference in New Issue
Block a user