@Test void testStartWith() { assertTrue(StringUtil.startsWithChar("asd", 'a')); assertFalse(StringUtil.startsWithChar("asd", 's')); assertFalse(StringUtil.startsWithChar("", 'a')); assertTrue(StringUtil.endsWithChar("asd", 'd')); assertFalse(StringUtil.endsWithChar("asd", 's')); assertFalse(StringUtil.endsWithChar("", 'd')); assertEquals(3, StringUtil.startsWithOne("qwe123", "Qwe", null, ".", "qwe")); assertEquals(-1, StringUtil.startsWithOne("qwe123", "Qwe", null, ".", "we")); assertEquals(0, StringUtil.startsWithOneIgnoreCase("qwe123", "Qwe", null, ".", "qwe")); assertEquals(-1, StringUtil.startsWithOneIgnoreCase("qwe123", "we", null, ".", "we")); assertEquals(3, StringUtil.endsWithOne("qwezxc", "Zxc", null, ".", "zxc")); assertEquals(-1, StringUtil.endsWithOne("qwezxc", "Zxc", null, ".", "zx")); assertEquals(0, StringUtil.endsWithOneIgnoreCase("qweZXC", "Zxc", null, ".", "zxc")); assertEquals(-1, StringUtil.endsWithOneIgnoreCase("qweZXC", "zx", null, ".", "zx")); }