From 476de8d2fff1136aa9e0a0450aade606aaed7878 Mon Sep 17 00:00:00 2001 From: simeng-li Date: Thu, 29 Jun 2023 13:59:23 +0800 Subject: [PATCH] chore(core,ui): set jest config coverage report to all files (#4090) set jest config coverage report to all files --- packages/core/jest.config.js | 1 + packages/ui/jest.config.ts | 3 +++ 2 files changed, 4 insertions(+) diff --git a/packages/core/jest.config.js b/packages/core/jest.config.js index 305244652..dad1a7aff 100644 --- a/packages/core/jest.config.js +++ b/packages/core/jest.config.js @@ -1,6 +1,7 @@ /** @type {import('jest').Config} */ const config = { transform: {}, + collectCoverageFrom: ['**/*.{js,ts}'], coveragePathIgnorePatterns: ['/node_modules/', '/src/__mocks__/'], coverageReporters: ['text-summary', 'lcov'], coverageProvider: 'v8', diff --git a/packages/ui/jest.config.ts b/packages/ui/jest.config.ts index 47305ffc4..8ab5d388c 100644 --- a/packages/ui/jest.config.ts +++ b/packages/ui/jest.config.ts @@ -4,6 +4,9 @@ const config: Config.InitialOptions = { roots: ['/src'], testEnvironment: 'jsdom', setupFilesAfterEnv: ['/src/jest.setup.ts'], + collectCoverageFrom: ['**/*.{js,jsx,ts,tsx}'], + coveragePathIgnorePatterns: ['/node_modules/', '/src/__mocks__/', '/src/include.d/'], + coverageReporters: ['text-summary', 'lcov'], transform: { '^.+\\.(t|j)sx?$': [ '@swc/jest',