module.exports = {
    "host" : "http://Administrator:ok@localhost:5984",
    "admin_db" : "test_sp_admin",
    "users_db" : "test_sp_users"
}

@@ -1,76 +1,536 @@
-module.exports = %7B%0A    %22host%22 : %22http://Administrator:ok@localhost:5984%22
+var fs = require('fs'),  %0A  path = require(%22path%22),%0A  configPath = path.join(__dirname, %22..%22,%22config.json%22),%0A  ok = false,%0A  config = fs.readFileSync(configPath, %22utf8%22);%0A%0Atry %7B%0A  config = JSON.parse(config);%0A  ok = true;%0A%7D catch (e) %7B%0A  console.error(%22could not read config.json, please use %60npm start syncpoint%60 to set up your installation: %22+configPath);%0A%7D%0A%0A// we use the configured host but test databases.%0A// if there is a test_host configured we use that instead%0Amodule.exports = %7B%0A    %22host%22 : config.test_host %7C%7C config.host
 ,%0A  

test config picks up host (and admin credentials) from master config