From: Feross Aboukhadijeh Date: Wed, 29 Oct 2014 03:39:18 +0000 (-0700) Subject: fix bug in tests X-Git-Url: https://zoso.dev/?a=commitdiff_plain;h=0db5796eb3523b16093f01e02795ff40619a9aed;p=buffer.git fix bug in tests --- diff --git a/test/basic.js b/test/basic.js index 0c02ee5..cdaa37d 100644 --- a/test/basic.js +++ b/test/basic.js @@ -45,7 +45,7 @@ test('setting index value should modify buffer contents', function (t) { test('storing negative number should cast to unsigned', function (t) { var buf = new B(1) - if (Buffer.TYPED_ARRAY_SUPPORT) { + if (B.TYPED_ARRAY_SUPPORT) { // This does not work with the object implementation -- nothing we can do! buf[0] = -3 t.equal(buf[0], 253) diff --git a/test/write.js b/test/write.js index 5460246..550ca8a 100644 --- a/test/write.js +++ b/test/write.js @@ -66,7 +66,7 @@ test('hex of write{Uint,Int}{8,16,32}{LE,BE}', function (t) { }) test('hex of write{Uint,Int}{8,16,32}{LE,BE} with overflow', function (t) { - if (!Buffer.TYPED_ARRAY_SUPPORT) { + if (!B.TYPED_ARRAY_SUPPORT) { t.pass('object impl: skipping overflow test') t.end() return