From 8b9b74884f6228d9f0135ea7dc9e80e035b61ad3 Mon Sep 17 00:00:00 2001 From: Felix <5724535+FelixGraf@users.noreply.github.com> Date: Thu, 17 Aug 2023 14:47:42 +0200 Subject: [PATCH 1/3] fix: add workspace config files to default coverage excludes --- docs/config/index.md | 1 + packages/vitest/src/defaults.ts | 1 + 2 files changed, 2 insertions(+) diff --git a/docs/config/index.md b/docs/config/index.md index 54922d6b2d8d..bd1145d03e1d 100644 --- a/docs/config/index.md +++ b/docs/config/index.md @@ -899,6 +899,7 @@ List of files included in coverage as glob patterns '**/*{.,-}{test,spec}.?(c|m)[jt]s?(x)', '**/__tests__/**', '**/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build}.config.*', + '**/vitest.{workspace,projects}.[jt]s', '**/.{eslint,mocha,prettier}rc.{?(c|m)js,yml}', ] ``` diff --git a/packages/vitest/src/defaults.ts b/packages/vitest/src/defaults.ts index 2f80f9e85321..a7962368e844 100644 --- a/packages/vitest/src/defaults.ts +++ b/packages/vitest/src/defaults.ts @@ -24,6 +24,7 @@ const defaultCoverageExcludes = [ '**/*{.,-}{test,spec}.?(c|m)[jt]s?(x)', '**/__tests__/**', '**/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build}.config.*', + '**/vitest.{workspace,projects}.[jt]s', '**/.{eslint,mocha,prettier}rc.{?(c|m)js,yml}', ] From 8001f373dbd127f7603131f0a2854e06643e4e26 Mon Sep 17 00:00:00 2001 From: Felix <5724535+FelixGraf@users.noreply.github.com> Date: Fri, 18 Aug 2023 10:55:14 +0200 Subject: [PATCH 2/3] Update docs/config/index.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Ari Perkkiƶ --- docs/config/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/config/index.md b/docs/config/index.md index bd1145d03e1d..601ddccbe275 100644 --- a/docs/config/index.md +++ b/docs/config/index.md @@ -899,7 +899,7 @@ List of files included in coverage as glob patterns '**/*{.,-}{test,spec}.?(c|m)[jt]s?(x)', '**/__tests__/**', '**/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build}.config.*', - '**/vitest.{workspace,projects}.[jt]s', + '**/vitest.{workspace,projects}.[jt]s?(on)', '**/.{eslint,mocha,prettier}rc.{?(c|m)js,yml}', ] ``` From 9e0176a0d80e2e20d6df032f8c6b53a942c7c754 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ari=20Perkki=C3=B6?= Date: Sat, 19 Aug 2023 09:48:36 +0300 Subject: [PATCH 3/3] fix: ignore workspace jsons --- packages/vitest/src/defaults.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/vitest/src/defaults.ts b/packages/vitest/src/defaults.ts index a7962368e844..518324bfe8e1 100644 --- a/packages/vitest/src/defaults.ts +++ b/packages/vitest/src/defaults.ts @@ -24,7 +24,7 @@ const defaultCoverageExcludes = [ '**/*{.,-}{test,spec}.?(c|m)[jt]s?(x)', '**/__tests__/**', '**/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build}.config.*', - '**/vitest.{workspace,projects}.[jt]s', + '**/vitest.{workspace,projects}.[jt]s?(on)', '**/.{eslint,mocha,prettier}rc.{?(c|m)js,yml}', ]