// config should be imported before importing any other fileconstconfig=require('./config/config');constapp=require('./config/express');require('./config/mongoose');// module.parent check is required to support mocha watch// src: https://github.com/mochajs/mocha/issues/1912if(!module.parent){app.listen(config.port,()=>{console.info(`server started on port ${config.port} (${config.env})`);});}module.exports=app;