1 var common = require('../common.js');
2 var PORT = common.PORT;
4 var bench = common.createBenchmark(main, {
5 // unicode confuses ab on os x.
6 type: ['bytes', 'buffer'],
7 length: [4, 1024, 102400],
8 chunks: [0, 1, 4], // chunks=0 means 'no chunked encoding'.
13 process.env.PORT = PORT;
14 var spawn = require('child_process').spawn;
15 var server = require('../http_simple.js');
16 setTimeout(function() {
17 var path = '/' + conf.type + '/' + conf.length + '/' + conf.chunks;
18 var args = ['-d', '10s', '-t', 8, '-c', conf.c];
20 bench.http(path, args, function() {