From e1de5742b066feb38cac14a4e4c397356263dfec Mon Sep 17 00:00:00 2001 From: Feross Aboukhadijeh Date: Wed, 5 Aug 2015 14:44:13 +0200 Subject: [PATCH] test: run arraybuffer test only with typed array supprot --- bin/download-node-tests.js | 11 ++++++++--- test/{node => node-es6}/test-buffer-arraybuffer.js | 0 2 files changed, 8 insertions(+), 3 deletions(-) rename test/{node => node-es6}/test-buffer-arraybuffer.js (100%) diff --git a/bin/download-node-tests.js b/bin/download-node-tests.js index 2556faa..53c1c70 100755 --- a/bin/download-node-tests.js +++ b/bin/download-node-tests.js @@ -13,8 +13,8 @@ var dirs = [ '/test/pummel' ] -cp.execSync('rm -r node/*.js', { cwd: __dirname + '/../test' }) -cp.execSync('rm -r node-es6/*.js', { cwd: __dirname + '/../test' }) +cp.execSync('rm -rf node/*.js', { cwd: __dirname + '/../test' }) +cp.execSync('rm -rf node-es6/*.js', { cwd: __dirname + '/../test' }) var httpOpts = { headers: { @@ -39,7 +39,8 @@ function downloadBufferTests (dir, files) { if (!/test-buffer.*/.test(file.name)) return var path - if (file.name === 'test-buffer-iterator.js') { + if (file.name === 'test-buffer-iterator.js' || + file.name === 'test-buffer-arraybuffer.js') { path = __dirname + '/../test/node-es6/' + file.name } else if (file.name === 'test-buffer-fakes.js') { // These teses only apply to node, where they're calling into C++ and need to @@ -49,10 +50,14 @@ function downloadBufferTests (dir, files) { path = __dirname + '/../test/node/' + file.name } + console.log(file.download_url) hyperquest(file.download_url, httpOpts) .pipe(split()) .pipe(testfixer(file.name)) .pipe(fs.createWriteStream(path)) + .on('finish', function () { + console.log('wrote ' + file.name) + }) }) } diff --git a/test/node/test-buffer-arraybuffer.js b/test/node-es6/test-buffer-arraybuffer.js similarity index 100% rename from test/node/test-buffer-arraybuffer.js rename to test/node-es6/test-buffer-arraybuffer.js -- 2.34.1