Added middelware/test.js for testing

* changed response in mongo/errors.js - it will return message key instead of message