Skip to content

evolvator/travis-benchmark

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

travis-benchmark

Generate json results for benchmark.js.

NPM Build Status

About

  • Dont work outside the travis environment.
  • Write results into file travisBuildId.json.
  • Other config same as in travis-json-git-log, but with build and job fields for additional benchmark info.

Example

var Benchmark = require('benchmark');
var tb = require('travis-benchmark');

var suite = new Benchmark.Suite('suiteName');
tb.wrapSuite(suite/*, callback, config*/);
.run({ 'async': true });

or

var Benchmark = require('benchmark');
var tb = require('travis-benchmark');
var tjgl = require('travis-json-git-log');

var suite = new Benchmark.Suite('suiteName');
suite.add('benchmarkName', function() {})
.on('complete', function(event) {
  var data = exports.parseSuite(event);
  tjgl.tjgl(
    _.extend({}, { data }, config),
    function(error, context, config) {}
  );
})
.run({ 'async': true });

Results

Result json file will contains:

  • build: number
  • job: number
  • platform: string
  • version: string
  • layout: string?
  • os: string
  • suite: string?
  • benchmark: string?
  • speed: number
  • distortion: number
  • sampled: number
  • percent: number
  • error?: string

About

📥 Generate json results for benchmark.js

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published