tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

buffer-util.test.js (360B)


      1 'use strict';
      2 
      3 const assert = require('assert');
      4 
      5 const { concat } = require('../lib/buffer-util');
      6 
      7 describe('bufferUtil', () => {
      8  describe('concat', () => {
      9    it('never returns uninitialized data', () => {
     10      const buf = concat([Buffer.from([1, 2]), Buffer.from([3, 4])], 6);
     11 
     12      assert.ok(buf.equals(Buffer.from([1, 2, 3, 4])));
     13    });
     14  });
     15 });