mirror of
https://gitee.com/dromara/hutool.git
synced 2025-04-05 17:37:59 +08:00
多个字段是否全部不为空
This commit is contained in:
parent
f349d770e2
commit
f6860cc555
File diff suppressed because it is too large
Load Diff
@ -289,4 +289,12 @@ public class ArrayUtilTest {
|
||||
final int[] ints = ArrayUtil.addAll(new int[]{1, 2, 3}, new int[]{4, 5, 6});
|
||||
Assert.assertArrayEquals(new int[]{1,2,3,4,5,6}, ints);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void isAllNotNullTest(){
|
||||
String[] allNotNull = {"aa", "bb", "cc", "dd", "bb", "dd"};
|
||||
Assert.assertTrue(ArrayUtil.isAllNotNull(allNotNull));
|
||||
String[] hasNull = {"aa", "bb", "cc", null, "bb", "dd"};
|
||||
Assert.assertFalse(ArrayUtil.isAllNotNull(hasNull));
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user