UNPKG

ac-node

Version:

A common module for building Atlassian Connect add-ons

62 lines (42 loc) 1.6 kB
[ ![Codeship Status for rbergman/ac-node](https://codeship.io/projects/95f3ed00-fbbf-0131-9c0c-6695216aa8a8/status)](https://codeship.io/projects/29243) What? ===== This is a common module shared by product-specific libraries useful in the development of Atlassian Connect add-ons. The main library source is written to be compatible with Node.js v0.10.x, but the tests rely on ES6 generators, which means you must use Node.js v0.11.x to run the tests. Using `nvm` to manage multiple Node.js versions is recommended. Running Tests ============= You'll need both `redis` and `mongodb` to run the complete the full test suite. If you don't have them, get them with an OS-appropriate package manager. On OS X, for example, [brew](http://brew.sh) is recommended. ``` $ brew install redis mongodb ``` Next, if you don't have `nvm`, install it. It's not strictly required, but will aid tremendously in running multiple versions of Node.js. ``` $ curl https://raw.githubusercontent.com/creationix/nvm/v0.12.1/install.sh | bash ``` For more advanced help with `nvm`, see its [website](https://github.com/creationix/nvm). If you need Node.js v0.11.x, install and select it. ``` $ nvm install v0.11.13 $ nvm use v0.11.13 ``` Next, make sure you have this repository's dependencies installed. ``` $ cd ac-node $ npm install ``` Finally, run the full test suite. ``` $ npm test ``` To skip slow-running tests: ``` $ NODE_TEST=fast npm test ``` To skip the redis and mongodb tests: ``` $ NODE_TEST="no-redis no-mongo" npm test ```