Skip to content

Commit

Permalink
Drop cross-env npm dep
Browse files Browse the repository at this point in the history
  • Loading branch information
lnicola committed Jun 30, 2023
1 parent 40b2a68 commit 0edacbd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 1 addition & 2 deletions editors/code/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"lint": "prettier --check . && eslint -c .eslintrc.js --ext ts ./src ./tests",
"fix": "prettier --write . && eslint -c .eslintrc.js --ext ts ./src ./tests --fix",
"pretest": "tsc && npm run build",
"test": "cross-env TEST_VARIABLE=test node ./out/tests/runTests.js"
"test": "node ./out/tests/runTests.js"
},
"dependencies": {
"@hpcc-js/wasm": "^2.13.0",
Expand All @@ -55,7 +55,6 @@
"@typescript-eslint/parser": "^5.60.1",
"@vscode/test-electron": "^2.3.3",
"@vscode/vsce": "^2.19.0",
"cross-env": "^7.0.3",
"esbuild": "^0.18.10",
"eslint": "^8.43.0",
"eslint-config-prettier": "^8.8.0",
Expand Down
2 changes: 2 additions & 0 deletions editors/code/tests/unit/settings.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ export async function getTests(ctx: Context) {
});

suite.addTest("Should support external variables", async () => {
process.env["TEST_VARIABLE"] = "test";
const envJson = {
USING_EXTERNAL_VAR: "${env:TEST_VARIABLE} test ${env:TEST_VARIABLE}",
};
Expand All @@ -48,6 +49,7 @@ export async function getTests(ctx: Context) {

const actualEnv = await substituteVariablesInEnv(envJson);
assert.deepStrictEqual(actualEnv, expectedEnv);
delete process.env["TEST_VARIABLE"];
});

suite.addTest("should support VSCode variables", async () => {
Expand Down

0 comments on commit 0edacbd

Please sign in to comment.