Skip to content

Commit 9792c81

Browse files
committed
chore: update variable to be understandable
1 parent 92ac637 commit 9792c81

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
11
'use strict';
22

33
const { run } = require('../utils/test-utils');
4-
const pkgLock = require('../../package.json');
4+
const pkgJSON = require('../../package.json');
55

66
describe('version flag with multiple arguments', () => {
77
it('outputs version with mixed syntax', () => {
88
const { stdout, stderr } = run(__dirname, ['--version', '--target', 'browser']);
9-
expect(stdout).toContain(pkgLock.version);
9+
expect(stdout).toContain(pkgJSON.version);
1010
expect(stderr).toHaveLength(0);
1111
});
1212

1313
it('outputs version with multiple commands', () => {
1414
const { stdout, stderr } = run(__dirname, ['version', 'init']);
15-
expect(stdout).toContain(pkgLock.version);
15+
expect(stdout).toContain(pkgJSON.version);
1616
expect(stderr).toHaveLength(0);
1717
});
1818

1919
it('does not output version with help command', () => {
2020
const { stdout, stderr } = run(__dirname, ['version', 'help']);
21-
expect(stdout).not.toContain(pkgLock.version);
21+
expect(stdout).not.toContain(pkgJSON.version);
2222

2323
const uniqueIdentifier = 'Made with ♥️ by the webpack team';
2424
expect(stdout).toContain(uniqueIdentifier);
@@ -27,7 +27,7 @@ describe('version flag with multiple arguments', () => {
2727

2828
it('does not output version with help dashed', () => {
2929
const { stdout, stderr } = run(__dirname, ['version', '--help']);
30-
expect(stdout).not.toContain(pkgLock.version);
30+
expect(stdout).not.toContain(pkgJSON.version);
3131

3232
const uniqueIdentifier = 'Made with ♥️ by the webpack team';
3333
expect(stdout).toContain(uniqueIdentifier);
@@ -36,7 +36,7 @@ describe('version flag with multiple arguments', () => {
3636

3737
it('outputs version with multiple dashed args and has precidence', () => {
3838
const { stdout, stderr } = run(__dirname, ['--target', 'browser', '--version']);
39-
expect(stdout).toContain(pkgLock.version);
39+
expect(stdout).toContain(pkgJSON.version);
4040
expect(stderr).toHaveLength(0);
4141
});
4242
});
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
11
'use strict';
22

33
const { run } = require('../utils/test-utils');
4-
const pkgLock = require('../../package.json');
4+
const pkgJSON = require('../../package.json');
55

66
describe('single version flag', () => {
77
it('outputs versions with command syntax', () => {
88
const { stdout, stderr } = run(__dirname, ['version']);
9-
expect(stdout).toContain(pkgLock.version);
9+
expect(stdout).toContain(pkgJSON.version);
1010
expect(stderr).toHaveLength(0);
1111
});
1212

1313
it('outputs versions with dashed syntax', () => {
1414
const { stdout, stderr } = run(__dirname, ['--version']);
15-
expect(stdout).toContain(pkgLock.version);
15+
expect(stdout).toContain(pkgJSON.version);
1616
expect(stderr).toHaveLength(0);
1717
});
1818
});

0 commit comments

Comments
 (0)