Add integration test for global bans
This commit is contained in:
parent
8ad9b4e543
commit
b80a87ba01
5 changed files with 119 additions and 9 deletions
|
|
@ -48,8 +48,12 @@ class Database {
|
|||
|
||||
module.exports.Database = Database;
|
||||
|
||||
module.exports.init = function () {
|
||||
db = new Database();
|
||||
module.exports.init = function (newDB) {
|
||||
if (newDB) {
|
||||
db = newDB;
|
||||
} else {
|
||||
db = new Database();
|
||||
}
|
||||
db.knex.raw('select 1 from dual')
|
||||
.catch(error => {
|
||||
LOGGER.error('Initial database connection failed: %s', error.stack);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue