ResponseUtils { public static boolean isSucceed(final byte[] pByte) { return contains(pByte, SwEnum.SW_9000); } private  ResponseUtils(); static boolean isSucceed(final byte[] pByte); static boolean isEquals(final byte[] pByte, final SwEnum pEnum); static boolean contains(final byte[] pByte, final SwEnum... pEnum);  }
@Test public void testResponseIsSucceed() { Assertions.assertThat(ResponseUtils.isSucceed(new byte[] { (byte) 0x90, 0 })).isEqualTo(true); Assertions.assertThat(ResponseUtils.isSucceed(new byte[] { 0, (byte) 0x90, 0 })).isEqualTo(true); Assertions.assertThat(ResponseUtils.isSucceed(new byte[] { (byte) 0x00, 0 })).isEqualTo(false); Assertions.assertThat(ResponseUtils.isSucceed(null)).isEqualTo(false); }