From 9ed4612ab7a8e7f6d72c55b05d71b9ef44059773 Mon Sep 17 00:00:00 2001 From: Carl Hamilton <4007311+cahamilton@users.noreply.github.com> Date: Fri, 15 Dec 2023 14:51:30 +0000 Subject: [PATCH] Silence CJS deprecation warnings --- __tests__/index.test.js | 6 +++++- package.json | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/__tests__/index.test.js b/__tests__/index.test.js index f0a7bcc..46c9f13 100644 --- a/__tests__/index.test.js +++ b/__tests__/index.test.js @@ -11,7 +11,11 @@ const index = require('../index'); * @return {Promise<{errored, invalidOptionWarnings, warnings}>} */ const lintCode = async ({ code, config }) => { - const actual = await stylelint.lint({ code, config }); + const actual = await stylelint.lint({ + code, + config, + quietDeprecationWarnings: true, + }); const { errored, results } = actual; const { invalidOptionWarnings, warnings } = results[0]; diff --git a/package.json b/package.json index b1e0272..c3b0dd8 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "scripts": { "coverage": "coveralls < coverage/lcov.info", "eslint": "eslint .", - "jest": "jest", + "jest": "NODE_OPTIONS=\"--experimental-vm-modules --no-warnings\" jest", "prettier": "prettier --check '**/*.js'", "test": "npm run eslint && npm run prettier && npm run jest" },