Skip to content

Testing how to

tmeasday edited this page Nov 12, 2012 · 5 revisions

Testing

How to run tests

npm test

Or

mocha spec/unit spec/acceptance -t 240000 -R spec

Atmosphere

Make sure you have a local atmosphere running on port 3333 (we use it to speed the tests up, but don't output a helpful message if its not there ! ):

  git clone https://github.com/oortcloud/atmosphere.git
  cd atmosphere/app
  mrt --port 3333

Refreshing test cache

Since mrt downloads git repos we cache the results so the test suite will run fast. It will be slow the first time.

When the related repos change you will need to flush the cache

npm run-script flushcache

TODO figure out a workaround for the following notes, use a patched version of mocha if we have to

Note: Can't use mocha's recursive option because it it breaks trying to processes files in the test apps as test files.

Note: Heh also can't seem to use --watch

Clone this wiki locally