Fix varargs compile warnings

This commit is contained in:
Sebb 2023-12-08 23:44:45 +00:00
parent ba729fc832
commit bb6d9b6384
1 changed files with 15 additions and 15 deletions

View File

@ -61,17 +61,17 @@ public class CharSetUtilsTest extends AbstractLangTest {
public void testContainsAny_StringStringarray() {
assertFalse(CharSetUtils.containsAny(null, (String[]) null));
assertFalse(CharSetUtils.containsAny(null));
assertFalse(CharSetUtils.containsAny(null, null));
assertFalse(CharSetUtils.containsAny(null, (String) null));
assertFalse(CharSetUtils.containsAny(null, "a-e"));
assertFalse(CharSetUtils.containsAny("", (String[]) null));
assertFalse(CharSetUtils.containsAny(""));
assertFalse(CharSetUtils.containsAny("", null));
assertFalse(CharSetUtils.containsAny("", (String) null));
assertFalse(CharSetUtils.containsAny("", "a-e"));
assertFalse(CharSetUtils.containsAny("hello", (String[]) null));
assertFalse(CharSetUtils.containsAny("hello"));
assertFalse(CharSetUtils.containsAny("hello", null));
assertFalse(CharSetUtils.containsAny("hello", (String) null));
assertTrue(CharSetUtils.containsAny("hello", "a-e"));
assertTrue(CharSetUtils.containsAny("hello", "el"));
@ -100,17 +100,17 @@ public class CharSetUtilsTest extends AbstractLangTest {
public void testCount_StringStringarray() {
assertEquals(0, CharSetUtils.count(null, (String[]) null));
assertEquals(0, CharSetUtils.count(null));
assertEquals(0, CharSetUtils.count(null, null));
assertEquals(0, CharSetUtils.count(null, (String) null));
assertEquals(0, CharSetUtils.count(null, "a-e"));
assertEquals(0, CharSetUtils.count("", (String[]) null));
assertEquals(0, CharSetUtils.count(""));
assertEquals(0, CharSetUtils.count("", null));
assertEquals(0, CharSetUtils.count("", (String) null));
assertEquals(0, CharSetUtils.count("", "a-e"));
assertEquals(0, CharSetUtils.count("hello", (String[]) null));
assertEquals(0, CharSetUtils.count("hello"));
assertEquals(0, CharSetUtils.count("hello", null));
assertEquals(0, CharSetUtils.count("hello", (String) null));
assertEquals(1, CharSetUtils.count("hello", "a-e"));
assertEquals(3, CharSetUtils.count("hello", "el"));
@ -140,17 +140,17 @@ public class CharSetUtilsTest extends AbstractLangTest {
public void testDelete_StringStringarray() {
assertNull(CharSetUtils.delete(null, (String[]) null));
assertNull(CharSetUtils.delete(null));
assertNull(CharSetUtils.delete(null, null));
assertNull(CharSetUtils.delete(null, (String) null));
assertNull(CharSetUtils.delete(null, "el"));
assertEquals("", CharSetUtils.delete("", (String[]) null));
assertEquals("", CharSetUtils.delete(""));
assertEquals("", CharSetUtils.delete("", null));
assertEquals("", CharSetUtils.delete("", (String) null));
assertEquals("", CharSetUtils.delete("", "a-e"));
assertEquals("hello", CharSetUtils.delete("hello", (String[]) null));
assertEquals("hello", CharSetUtils.delete("hello"));
assertEquals("hello", CharSetUtils.delete("hello", null));
assertEquals("hello", CharSetUtils.delete("hello", (String) null));
assertEquals("hello", CharSetUtils.delete("hello", "xyz"));
assertEquals("ho", CharSetUtils.delete("hello", "el"));
@ -183,17 +183,17 @@ public class CharSetUtilsTest extends AbstractLangTest {
public void testKeep_StringStringarray() {
assertNull(CharSetUtils.keep(null, (String[]) null));
assertNull(CharSetUtils.keep(null));
assertNull(CharSetUtils.keep(null, null));
assertNull(CharSetUtils.keep(null, (String) null));
assertNull(CharSetUtils.keep(null, "a-e"));
assertEquals("", CharSetUtils.keep("", (String[]) null));
assertEquals("", CharSetUtils.keep(""));
assertEquals("", CharSetUtils.keep("", null));
assertEquals("", CharSetUtils.keep("", (String) null));
assertEquals("", CharSetUtils.keep("", "a-e"));
assertEquals("", CharSetUtils.keep("hello", (String[]) null));
assertEquals("", CharSetUtils.keep("hello"));
assertEquals("", CharSetUtils.keep("hello", null));
assertEquals("", CharSetUtils.keep("hello", (String) null));
assertEquals("e", CharSetUtils.keep("hello", "a-e"));
assertEquals("e", CharSetUtils.keep("hello", "a-e"));
@ -225,17 +225,17 @@ public class CharSetUtilsTest extends AbstractLangTest {
public void testSqueeze_StringStringarray() {
assertNull(CharSetUtils.squeeze(null, (String[]) null));
assertNull(CharSetUtils.squeeze(null));
assertNull(CharSetUtils.squeeze(null, null));
assertNull(CharSetUtils.squeeze(null, (String) null));
assertNull(CharSetUtils.squeeze(null, "el"));
assertEquals("", CharSetUtils.squeeze("", (String[]) null));
assertEquals("", CharSetUtils.squeeze(""));
assertEquals("", CharSetUtils.squeeze("", null));
assertEquals("", CharSetUtils.squeeze("", (String) null));
assertEquals("", CharSetUtils.squeeze("", "a-e"));
assertEquals("hello", CharSetUtils.squeeze("hello", (String[]) null));
assertEquals("hello", CharSetUtils.squeeze("hello"));
assertEquals("hello", CharSetUtils.squeeze("hello", null));
assertEquals("hello", CharSetUtils.squeeze("hello", (String) null));
assertEquals("hello", CharSetUtils.squeeze("hello", "a-e"));
assertEquals("helo", CharSetUtils.squeeze("hello", "el"));