From b7fcb0ae42a167a3ff1e46b2b0bfa9d6a8db1bb5 Mon Sep 17 00:00:00 2001 From: Matthew O'Connor Date: Thu, 22 Oct 2020 21:54:08 +0100 Subject: [PATCH] =?UTF-8?q?code=C2=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jest.config.base.js | 2 +- .../splitview/src/__tests__/api/api.spec.ts | 6 ++--- tsconfig.test.json | 22 +++++++++++++++++++ 3 files changed, 26 insertions(+), 4 deletions(-) create mode 100644 tsconfig.test.json diff --git a/jest.config.base.js b/jest.config.base.js index eeb0765ab..287c2f74f 100644 --- a/jest.config.base.js +++ b/jest.config.base.js @@ -1,6 +1,6 @@ const {join, normalize} = require("path"); -const tsConfig = normalize(join(__dirname, "tsconfig.build.json")) +const tsConfig = normalize(join(__dirname, "tsconfig.test.json")) module.exports = { displayName: { name: "root" }, diff --git a/packages/splitview/src/__tests__/api/api.spec.ts b/packages/splitview/src/__tests__/api/api.spec.ts index efb3ab53d..ab175158e 100644 --- a/packages/splitview/src/__tests__/api/api.spec.ts +++ b/packages/splitview/src/__tests__/api/api.spec.ts @@ -57,13 +57,13 @@ describe('api', () => { }); it('should update isActive getter', () => { - expect(api.isVisible).toBeFalsy(); - - api._onDidVisibilityChange.fire({ isVisible: true }); expect(api.isVisible).toBeTruthy(); api._onDidVisibilityChange.fire({ isVisible: false }); expect(api.isVisible).toBeFalsy(); + + api._onDidVisibilityChange.fire({ isVisible: true }); + expect(api.isVisible).toBeTruthy(); }); it('should update width and height getter', () => { diff --git a/tsconfig.test.json b/tsconfig.test.json new file mode 100644 index 000000000..d58b7d79f --- /dev/null +++ b/tsconfig.test.json @@ -0,0 +1,22 @@ + +{ + "compilerOptions": { + "module": "commonjs", + "target": "es2019", + "sourceMap": true, + "declaration": true, + "jsx": "react", + "noImplicitReturns": true, + "noImplicitAny": true, + "allowUnreachableCode": false, + "forceConsistentCasingInFileNames": true, + // "strict": true, + "strictBindCallApply": true, // pass + "alwaysStrict": true, // pass + "noImplicitThis": true, // pass + "strictFunctionTypes": true, // pass + "strictNullChecks": false, + "strictPropertyInitialization": false, + }, + "exclude": ["node_modules", "dist"] +} \ No newline at end of file