Node `mocha` automatically sets environment and runs tests if you are using mocha runner, manual settings and running lead to errors.