Skip to content

Commit abaf51e

Browse files
authored
Tests: Add tests for lockfile version (#2106)
* Add tests for lockfile version * add resolveJsonModule for typecheck
1 parent 03f3427 commit abaf51e

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import lockFile from '../../package-lock.json'
2+
import docsLockFile from '../../docs/package-lock.json'
3+
4+
test('root: lockfileVersion should be 2', async () => {
5+
expect(lockFile.lockfileVersion).toEqual(2)
6+
})
7+
8+
test('docs: lockfileVersion should be 2', async () => {
9+
expect(docsLockFile.lockfileVersion).toEqual(2)
10+
})

tsconfig.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
"esModuleInterop": true,
1414
"skipLibCheck": true,
1515
"forceConsistentCasingInFileNames": true,
16+
"resolveJsonModule": true,
1617
"typeRoots": ["./node_modules/@types", "./@types"]
1718
},
1819
"include": ["@types/**/*.ts", "src/**/*.js", "src/**/*.ts", "src/**/*.tsx", "script/**/*.ts"]

0 commit comments

Comments
 (0)