From 6b796258d413f00e498ce7f80f73a9f6c061f29c Mon Sep 17 00:00:00 2001 From: RaindropsSys Date: Sat, 30 Mar 2024 23:40:33 +0100 Subject: Updated 5 files, added 2 files, deleted 495 files and renamed 7 files (automated) --- .../external/signal/node_modules/asynckit/bench.js | 76 ---------------------- 1 file changed, 76 deletions(-) delete mode 100644 includes/external/signal/node_modules/asynckit/bench.js (limited to 'includes/external/signal/node_modules/asynckit/bench.js') diff --git a/includes/external/signal/node_modules/asynckit/bench.js b/includes/external/signal/node_modules/asynckit/bench.js deleted file mode 100644 index c612f1a..0000000 --- a/includes/external/signal/node_modules/asynckit/bench.js +++ /dev/null @@ -1,76 +0,0 @@ -/* eslint no-console: "off" */ - -var asynckit = require('./') - , async = require('async') - , assert = require('assert') - , expected = 0 - ; - -var Benchmark = require('benchmark'); -var suite = new Benchmark.Suite; - -var source = []; -for (var z = 1; z < 100; z++) -{ - source.push(z); - expected += z; -} - -suite -// add tests - -.add('async.map', function(deferred) -{ - var total = 0; - - async.map(source, - function(i, cb) - { - setImmediate(function() - { - total += i; - cb(null, total); - }); - }, - function(err, result) - { - assert.ifError(err); - assert.equal(result[result.length - 1], expected); - deferred.resolve(); - }); -}, {'defer': true}) - - -.add('asynckit.parallel', function(deferred) -{ - var total = 0; - - asynckit.parallel(source, - function(i, cb) - { - setImmediate(function() - { - total += i; - cb(null, total); - }); - }, - function(err, result) - { - assert.ifError(err); - assert.equal(result[result.length - 1], expected); - deferred.resolve(); - }); -}, {'defer': true}) - - -// add listeners -.on('cycle', function(ev) -{ - console.log(String(ev.target)); -}) -.on('complete', function() -{ - console.log('Fastest is ' + this.filter('fastest').map('name')); -}) -// run async -.run({ 'async': true }); -- cgit