1 import mergeUint8Arrays from './mergeUint8Arrays';
3 describe('mergeUint8Arrays()', () => {
4 it('returns empty array if arrays is empty', () => {
5 const arrays: Uint8Array[] = [];
7 const result = mergeUint8Arrays(arrays);
9 expect(result).toStrictEqual(new Uint8Array());
12 it('merges Uint8Array', () => {
13 const arrays = [new Uint8Array([1, 2, 3]), new Uint8Array([4, 5, 6])];
15 const result = mergeUint8Arrays(arrays);
17 expect(result).toStrictEqual(new Uint8Array([1, 2, 3, 4, 5, 6]));