build: ensure that we bundle the correct version of @types/node (#19102)
This commit is contained in:
parent
5a1b661f42
commit
4b674c1daf
2 changed files with 11 additions and 1 deletions
|
@ -9,7 +9,7 @@
|
|||
},
|
||||
"dependencies": {
|
||||
"@electron/get": "^1.0.1",
|
||||
"@types/node": "^10.12.18",
|
||||
"@types/node": "^12.0.12",
|
||||
"extract-zip": "^1.0.3"
|
||||
},
|
||||
"engines": {
|
||||
|
|
10
spec-main/types-spec.ts
Normal file
10
spec-main/types-spec.ts
Normal file
|
@ -0,0 +1,10 @@
|
|||
import { expect } from 'chai'
|
||||
|
||||
describe('bundled @types/node', () => {
|
||||
it('should match the major version of bundled node', () => {
|
||||
expect(require('../npm/package.json').dependencies).to.have.property('@types/node')
|
||||
const range = require('../npm/package.json').dependencies['@types/node']
|
||||
expect(range).to.match(/^\^.+/, 'should allow any type dep in a major range')
|
||||
expect(range.slice(1).split('.')[0]).to.equal(process.versions.node.split('.')[0])
|
||||
})
|
||||
})
|
Loading…
Add table
Add a link
Reference in a new issue