From a7e8c8e7a53f0d5199d9aa206cc764876025ee1a Mon Sep 17 00:00:00 2001 From: Kalin Krustev Date: Wed, 15 May 2024 22:14:32 +0000 Subject: [PATCH] fix: parse 'false' in env --- test/unit/lib/config.test.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/test/unit/lib/config.test.js b/test/unit/lib/config.test.js index 2e03c4199..5ee651792 100644 --- a/test/unit/lib/config.test.js +++ b/test/unit/lib/config.test.js @@ -44,13 +44,12 @@ Test('Config should', configTest => { configTest.test('evaluate MONGODB_DISABLED to a boolean if a string', async function (test) { console.log(Defaults) - const DefaultsStub = { ...Defaults } - DefaultsStub.MONGODB.DISABLED = 'true' const Config = Proxyquire('../../../src/lib/config', { - '../../config/default.json': DefaultsStub + '../../config/default.json': { ...Defaults, MONGODB: { DISABLED: 'true', DEBUG: 'true' } } }) test.ok(Config.MONGODB_DISABLED === true) + test.ok(Config.MONGODB_DEBUG === true) test.end() })