implementing Mocha tests