diff --git a/tests/helpers/log-message.test.js b/tests/helpers/log-message.test.js index e15207f73..eda2de100 100644 --- a/tests/helpers/log-message.test.js +++ b/tests/helpers/log-message.test.js @@ -34,34 +34,31 @@ test('Logs message conditionally', async (assert) => { assert.expect(2); // Log forced message - const FORCED1 = true; - const VERBOSE1 = false; - const source1 = { + let forced = true; + let source = { name: SCRIPTLET_NAME, ruleText: RULE_TEXT, - verbose: VERBOSE1, + verbose: false, }; - logMessage(source1, MESSAGE, FORCED1); + logMessage(source, MESSAGE, forced); // Log message on verbose - const FORCED2 = false; - const VERBOSE2 = true; - const source2 = { + forced = false; + source = { name: SCRIPTLET_NAME, ruleText: RULE_TEXT, - verbose: VERBOSE2, + verbose: true, }; - logMessage(source2, MESSAGE, FORCED2); + logMessage(source, MESSAGE, forced); // Message should not be logged this time, thus expected 2 asserts - const FORCED3 = false; - const VERBOSE3 = false; - const source3 = { + forced = false; + source = { name: SCRIPTLET_NAME, ruleText: RULE_TEXT, - verbose: VERBOSE3, + verbose: false, }; - logMessage(source3, MESSAGE, FORCED3); + logMessage(source, MESSAGE, forced); }); test('Logs message without ruleText', async (assert) => { @@ -78,10 +75,9 @@ test('Logs message without ruleText', async (assert) => { }; const FORCED = true; - const VERBOSE = false; const source = { name: SCRIPTLET_NAME, - verbose: VERBOSE, + verbose: false, }; logMessage(source, MESSAGE, FORCED); });