c9 / architect

A simple yet powerful plugin system for large-scale node applications
MIT License
982 stars 129 forks source link

Unit testing architect-controlled modules #12

Closed JoshuaGross closed 12 years ago

JoshuaGross commented 12 years ago

I just started moving some of my apps' modules into Architect, and I'm wondering if you have any tips about unit testing architect-controlled modules. Some logic can be exposed by setting module.exports.method = ... outside of the setup function, but what about modules that require registration before use?

I'm using Mocha for tests currently.

cadorn commented 12 years ago

See:

You should setup a config for architect and boot architect for each or groups of your tests.

JoshuaGross commented 12 years ago

Will have a look - thanks for the tip!