internal virtual void AssertByteArrayEquals(byte[] b1, byte[] b2) { if (b1.Length != b2.Length) { Assert.Fail("Byte arrays have different lengths: " + b1.Length + ", " + b2.Length); } for (int i = 0; i < b1.Length; i++) { if (b1[i] != b2[i]) { Assert.Fail("Byte arrays different at index " + i + ": " + b1[i] + ", " + b2[i]); } } }