From c2dd81f0a0c5369e8953afb1cb9d035e6663a746 Mon Sep 17 00:00:00 2001 From: Feross Aboukhadijeh Date: Tue, 10 Mar 2015 12:35:54 -0700 Subject: [PATCH] tests: don't bundle crypto-browserify (breaks old IEs) --- bin/download-node-tests.js | 2 +- test/node/test-buffer.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/download-node-tests.js b/bin/download-node-tests.js index 24fe48d..49abe18 100755 --- a/bin/download-node-tests.js +++ b/bin/download-node-tests.js @@ -92,7 +92,7 @@ function testfixer (filename) { // and crypto-browserify doesn't work in old // versions of ie if (filename === 'test-buffer.js') { - line = line.replace(/^(var crypto = require.*)/, '// $1') + line = line.replace(/^(\s*)(var crypto = require.*)/, '$1// $2') line = line.replace(/(crypto.createHash.*\))/, '1 /*$1*/') } diff --git a/test/node/test-buffer.js b/test/node/test-buffer.js index 9bb56e4..2c57965 100644 --- a/test/node/test-buffer.js +++ b/test/node/test-buffer.js @@ -1112,7 +1112,7 @@ assert.throws(function () { if (common.hasCrypto) { // Test truncation after decode - var crypto = require('crypto'); + // var crypto = require('crypto'); var b1 = new Buffer('YW55=======', 'base64'); var b2 = new Buffer('YW55', 'base64'); -- 2.34.1