testUint8ArrayToHex() {
    if (globalThis.Uint8Array === undefined) {
      // Uint8Array not supported.
      return;
    }

    assertEquals(
        // Java magic number
        'cafedead', crypt.byteArrayToHex(new Uint8Array([202, 254, 222, 173])));

    assertEquals(
        // IBM magic number
        'deadbeef', crypt.byteArrayToHex(new Uint8Array([222, 173, 190, 239])));

    assertEquals(
        'c0:ff:ee', crypt.byteArrayToHex(new Uint8Array([192, 255, 238]), ':'));
  }
Same as testByteArrayToHex but with Uint8Array instead of Array<number>.