From da879ea47fe0b1f2c08ebbaefb4098553a195851 Mon Sep 17 00:00:00 2001 From: cgole Date: Wed, 18 Nov 2015 14:37:46 -0800 Subject: [PATCH] Added db username password --- test/init.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/init.js b/test/init.js index 1bfb10c..8b0351c 100644 --- a/test/init.js +++ b/test/init.js @@ -3,15 +3,15 @@ module.exports = require('should'); var DataSource = require('loopback-datasource-juggler').DataSource; var config = require('rc')('loopback', {test: {mysql: {}}}).test.mysql; - +console.log(config) global.getConfig = function (options) { var dbConf = { host: process.env.MYSQL_HOST || config.host || 'localhost', port: process.env.MYSQL_PORT || config.port || 3306, database: 'myapp_test', - username: config.username, - password: config.password, + username: process.env.MYSQL_USERNAME || config.username, + password: process.env.MYSQL_PASSWORD || config.password, createDatabase: true };