const testbytesA = new StaticArray<u8>(32).fill(0)
const testbytesB = new StaticArray<u8>(32).fill(0)
for (let i = 0; i < 32; i++) {
- testbytesA[i] = 1
- if (equalbytes(testbytesA, testbytesB, 32)) {
- throw new Error('equalbytes failed unit test')
+ for (let j: u8 = 0; j < 8; j++) {
+ testbytesA[i] = 1 << j
+ if (equalbytes(testbytesA, testbytesB, 32)) { throw new Error('equalbytes failed unit test') }
+ testbytesA[i] = 0
}
- testbytesA[i] = 0
}