如何运行bluebird promise性能基准测试套件?

时间:2016-07-19 17:35:46

标签: promise bluebird

运行Bluebird Promise性能基准测试需要执行哪些命令?

https://github.com/petkaantonov/bluebird/tree/master/benchmark

1 个答案:

答案 0 :(得分:1)

您不必直接运行performance.js,而是通常使用可在根目录中找到的bench bash script。选项相当自我记录。

以下是一些示例调用:

node performance.js --n 10000 --t 1 doxbee-sequential/*.js
# for older node versions, you'll need the --harmony flag to run tests with generators

bench doxbee
bench parallel iojs # using a different engine that the default "node"
bench doxbee-errors node --prof # pass flags to node