How fast does your test suite run?


The test suite for a project I am working on runs in ~15,000 milliseconds with ~900 assertions. This includes all of my tests, JSHint, and JSCS (via Ember Suave). Because 15 seconds can feel a little long at times, I instead only test 1 module at a time using ember test -s -m 'module name here'. How do you go about testing? Do you test 1 module at a time or do you just run ember test -s because your test suite is faster? How long does your entire test suite take to run? Any tips you can provide? Thanks!


On one project my tests run in about 30 seconds… with 3000+ asserts… in this case I mostly run individual modules. and then run the whole test suite before I commit.

On other, smaller, projects where the tests run much quicker I just run all tests in one go.


I love this question!

We have a legacy app (pre 1.0) where we use Mocha and jsDom for testing. This isn’t just headless testing, we don’t have a browser at all. I love that workflow because I can run a spec from within vim using vim-spec. It will execute the spec that my cursor is currently on with 2 keys – Leader-s.

We’re still using Mocha in our new app (2.3) but I haven’t had a chance to configure Mocha to use jsDom to run the specs. I’ll usually keep the browser open to the specific module I’m working on to get feedback but it really isn’t the same TDD workflow. In the legacy app, I will often get lots of work done without even looking at the browser.

Once again, great question.


Thanks guys.

@andrew1, do you have any Ember-CLI apps with a solid test suite? If so, could you share the details?

@LozJackson, this is what I have been doing as well


What details are you interested in?


If you are using Ember CLI, how long does your test suite take to run? How many tests do you have?


We’ve got ~24 routes (most of these are interstitial routes that are really only there for progressive enhancement). I feel like we have decent test coverage with 229 tests that run in 41 seconds.

The project is, however, broken up so that there is a table addon and a ui addon that provide a lot of functionality and have their own test suites.

ui-kit: 10 tests (not good coverage) that run in 23 seconds tables: 56 tests (good coverage) that run in 23 seconds

One interesting thing is that Ember takes a long time to build before it starts running your tests.