From 31f4c95336fe1b87c5507e6dfe174ccfbd63743b Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Fri, 10 Nov 2023 10:56:35 +0100 Subject: [PATCH] disable composition when --test is true --- code/lib/core-common/src/utils/get-storybook-refs.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/code/lib/core-common/src/utils/get-storybook-refs.ts b/code/lib/core-common/src/utils/get-storybook-refs.ts index c0f530531b7e..accb63dfb67f 100644 --- a/code/lib/core-common/src/utils/get-storybook-refs.ts +++ b/code/lib/core-common/src/utils/get-storybook-refs.ts @@ -89,6 +89,10 @@ const toTitle = (input: string) => { }; export async function getRefs(options: Options) { + if (options.test) { + return {}; + } + const refs = await options.presets.apply>('refs', await getAutoRefs(options)); Object.entries(refs).forEach(([key, value]: [string, Ref]) => {