[Pkg-javascript-commits] [node-sha.js] 153/237: fix test

Bastien Roucariès rouca at moszumanska.debian.org
Fri May 5 09:03:49 UTC 2017


This is an automated email from the git hooks/post-receive script.

rouca pushed a commit to branch master
in repository node-sha.js.

commit b4e83fa8ef732e90c399fcde5f55f8417d623524
Author: Dominic Tarr <dominic.tarr at gmail.com>
Date:   Tue Sep 16 15:02:06 2014 +0300

    fix test
---
 test/hash.js | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)

diff --git a/test/hash.js b/test/hash.js
index cbbfa4a..349f9a9 100644
--- a/test/hash.js
+++ b/test/hash.js
@@ -1,5 +1,4 @@
 var hexpp = require('../hexpp').defaults({bigendian: false})
-var u = require('../util')
 var tape = require('tape')
 var Buffer = require('buffer/').Buffer
 var Hash = require('../hash')(Buffer)
@@ -38,7 +37,7 @@ var hh = 'abcdefhijklmnopq'
 var multi = {
       strings: ['abcd', 'efhijk', 'lmnopq'],
       buffers: [
-        toBuffer('abcdefhijklmnopq', 'ascii'),
+        new Buffer('abcdefhijklmnopq', 'ascii'),
         new Buffer([
          128,  0,  0,  0,    0,  0,  0,  0,
            0,  0,  0,  0,    0,  0,  0,  128
@@ -58,13 +57,6 @@ var long = {
       ]
     }
 
-
-function toBuffer (string, enc) {
-  var a = new Buffer(string.length)
-  u.write(a, string, enc, 0, 0, string.length, true)
-  return a
-}
-
 function makeTest(name, data) {
   tape(name, function (t) {
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-sha.js.git



More information about the Pkg-javascript-commits mailing list