eviltrout/ember-performance — pull request #4 by rjackson (2013-09-21 22:07:35+00:00)
Title: Refactor Profilers & Add Commandline Runner.

The major parts of this are:

* Perf.Profile is no longer a singleton.
* Perf.Profile is extended to make individual objects for each profile task.
* Each `Profiler` should implement the following:
* name - The name of the test.
* runCount - The count of runs for this particular profile.
* setup (**optional**) - This is run once before the actual method profile is started the first time.
* test - This is the actual method being run.
* teardown (**optional**) - Do any cleanup after the suite has finished.
* `Perf.ProfilerDisplay` was added as the main `ApplicationRoute` model.
* A console runner has been added.

**NOTE**: The original UI is still intact and fully functional.

#### Console Runner

Run with the following:

```
phantomjs runner.js index.html
```

The runner will create a results.json file in the project directory. I plan to change this in the future to report the test results to an external API server.

File format:

```javascript
[{"geometricMean":31.563778382196222,"mean":31.68,"name":"Object.create()","runCount":50,"standardDeviation":2.7308606701917246,"times":[29,33,34,37,33,28,28,30,27,30,30,28,35,39,34,29,35,29,30,30,33,34,32,34,33,31,33,30,30,34,33,31,30,33,37,30,33,33,30,33,33,36,27,28,29,28,30,32,33,33]},
{"geometricMean":28.013807173417142,"mean":28.125,"name":"Template Bindings","runCount":40,"standardDeviation":2.5902461273014192,"times":[27,29,28,26,27,35,31,27,27,28,27,34,28,28,27,27,35,28,28,27,29,28,33,25,26,25,25,33,28,28,25,25,26,29,27,28,27,27,30,27]},
{"geometricMean":19.179961026735317,"mean":19.225,"name":"HTML Bindings","runCount":40,"standardDeviation":1.31315459866689,"times":[19,18,17,20,19,20,20,20,20,20,20,20,20,21,20,23,18,17,17,17,17,17,20,21,19,20,20,19,20,19,19,20,19,18,19,19,19,21,18,19]}]
```