Skip to content

Commit 13110cc

Browse files
committed
Update cli.test.mjs
1 parent 0ce0d1c commit 13110cc

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

test/cli.test.mjs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
import { strict as assert } from 'node:assert';
22
import { spawnSync } from 'node:child_process';
3-
import path from 'node:path';
43
import process from 'node:process';
54
import { fileURLToPath } from 'node:url';
65

7-
const testDir = path.dirname(fileURLToPath(import.meta.url));
8-
const cliPath = path.resolve(testDir, '..', 'bin', 'cli.js');
6+
const cliPath = fileURLToPath(new URL('../bin/cli.js', import.meta.url));
97

10-
describe('dependency-tree CLI', () => {
8+
describe('cli', () => {
119
it('prints usage and exits when filename is missing', () => {
1210
const result = spawnSync(process.execPath, [cliPath], {
1311
encoding: 'utf8'

0 commit comments

Comments
 (0)