public void test(TestHarness harness) { harness.checkPoint("TestOfToByteArray"); try { BigInteger x = new BigInteger(BYTES); harness.verbose("*** x = 0x" + x.toString(16)); byte[] ba = x.toByteArray(); harness.check(Arrays.equals(ba, BYTES), true, "Byte arrays MUST be equal"); } catch (Exception x) { harness.debug(x); harness.fail("TestOfToByteArray: " + x); } }