Use module-location for unit tests

- To avoid inconsistent module exceptions
Cache config in server-field
Update mocha test

- Call initialize to make sure the correct config, application, domain is loaded