From 526199c932b2ddd226c3113f1de03ae0dbca6c2f Mon Sep 17 00:00:00 2001 From: "FUJI Goro (gfx)" Date: Fri, 15 Dec 2017 13:57:39 +0900 Subject: [PATCH] test package.json's dependencies not to include @types --- src/index.spec.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/index.spec.ts b/src/index.spec.ts index 567e84dc0..bb17919cd 100644 --- a/src/index.spec.ts +++ b/src/index.spec.ts @@ -15,8 +15,16 @@ const SOURCE_MAP_REGEXP = /\/\/# sourceMappingURL=data:application\/json;charset describe('ts-node', function () { this.timeout(10000) - it('should export the correct version', function () { - expect(VERSION).to.equal(require('../package.json').version) + describe('package.json', function () { + it('should export the correct version', function () { + expect(VERSION).to.equal(require('../package.json').version) + }) + + it('should not include @types in dependencies', function () { + const deps = require('../package.json').dependencies + // tslint:disable-next-line + expect(Object.keys(deps).filter((name) => /^@types\//.test(name))).to.be.empty + }) }) describe('cli', function () {