Using this module in other modules const nice = require("node-nice").nice; nice(() => { return calculatePi();}).then(result => { console.log("π = " + result);}); Setting travis and coveralls badges Sign in to travis and activate the build for your project. Sign in to coveralls and activate the build for your project.