From 21ffa8a110d3ea2f22da85cbb54ea6603528495d Mon Sep 17 00:00:00 2001 From: Daniel Cousens Date: Sat, 24 May 2014 19:32:09 +1000 Subject: [PATCH] add failing test for array of ints --- test/basic.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/basic.js b/test/basic.js index 48ee29c..53994fd 100644 --- a/test/basic.js +++ b/test/basic.js @@ -9,6 +9,14 @@ test('new buffer from array', function (t) { t.end() }) +test('new buffer from array w/ negatives', function (t) { + t.equal( + new B([-1, -2, -3]).toString('hex'), + 'fffefd' + ) + t.end() +}) + test('new buffer from string', function (t) { t.equal( new B('hey', 'utf8').toString(), -- 2.34.1