add Deferred tests using Mocha