Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: ensure that we bundle the correct version of @types/node #19102

Merged
merged 1 commit into from Jul 3, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion npm/package.json
Expand Up @@ -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": {
Expand Down
10 changes: 10 additions & 0 deletions spec-main/types-spec.ts
@@ -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])
})
})