From 18cfaca0f7085de9ffdc2c1ef8065571826d503f Mon Sep 17 00:00:00 2001 From: Francesco Trotta Date: Thu, 25 Apr 2024 11:58:32 +0200 Subject: [PATCH] chore: update dependency shelljs to ^0.8.5 (#600) chore: update dependency shelljs to v0.8.5 --- package.json | 2 +- tests/lib/libraries.js | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 445fdc0f..8b4ef8e8 100644 --- a/package.json +++ b/package.json @@ -51,7 +51,7 @@ "mocha": "^9.2.2", "npm-run-all": "^4.1.5", "rollup": "^2.41.2", - "shelljs": "^0.3.0", + "shelljs": "^0.8.5", "yorkie": "^2.0.0" }, "keywords": [ diff --git a/tests/lib/libraries.js b/tests/lib/libraries.js index e1f88766..9560cd48 100644 --- a/tests/lib/libraries.js +++ b/tests/lib/libraries.js @@ -13,6 +13,7 @@ import tester from "./tester.js"; import * as espree from "../../espree.js"; import assert from "assert"; import { fileURLToPath } from "url"; +import { readFile } from "fs/promises"; // eslint-disable-next-line no-underscore-dangle -- Conventional const __dirname = path.dirname(fileURLToPath(import.meta.url)); @@ -34,9 +35,9 @@ describe("Libraries", () => { // var filename = "angular-1.2.5.js"; - it("should produce correct AST when parsed", () => { - const output = shelljs.cat(`${filename}.result.json`); - const input = shelljs.cat(filename); + it("should produce correct AST when parsed", async () => { + const output = await readFile(`${filename}.result.json`, "utf-8"); + const input = await readFile(filename, "utf-8"); const result = JSON.stringify(tester.getRaw(espree.parse(input, { ecmaVersion: 5, loc: true,