benchie
A simple benchmark library for JavaScript
Last updated 6 years ago by pflannery .
Original npm · Tarball · package.json
$ cnpm install benchie 
SYNC missed versions from official npm registry.

Benchie JS (WIP)

Build Status NPM version Dependency Status Gittip donate button Bitdeli Badge

A simple benchmark library for JavaScript

##Usage

	npm install benchie
Simple Example:
	Benchmark = require("benchie").Benchmark
	var test = new Benchmark( "My Bench Test", function() { 
		// some code to test 
		var i = 2 * 2;
	});

	test.run();
	# outputs
	My Bench Test 221,982,195 x Avg ops per second
	My Bench Test 262,144,000 x Median ops per second

##Benchmark Options

name type args description
warmUpCount number Optional.
Default. 1024
How many times to call the test fn prior to running the test
cycleCount number Optional.
Default. 8
How many times to execute the test loop
testLoopCount number Optional.
Default. 1048576
How many times to run the test fn.
setup method Optional.
Method called before the first cycle begins
tearDown method Optional.
Method called after the last cycle end
cycleSetup method Optional.
Method called before each cycle begins
cycleTearDown method Optional.
Method called after each cycle ends
reporter class or array Optional.
Default. [AvergageReporter, MedianReporter]
Reporter(s) used to show formatted results.

History

You can discover the history inside the History.md file

Contributing

You can discover the contributing instructions inside the Contributing.md file

License

Licensed under the incredibly permissive MIT License
Copyright © 2013+ Stringz Solutions Ltd
Copyright © 2013+ Peter Flannery

Current Tags

  • 0.0.1                                ...           latest (6 years ago)

1 Versions

  • 0.0.1                                ...           6 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 2
Last Day 0
Last Week 0
Last Month 0
Dependencies (1)
Dev Dependencies (0)
None
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |