From b877ce86cb22e078fadb1af8529237e7602ad23d Mon Sep 17 00:00:00 2001 From: Jake Howell Date: Tue, 14 Jul 2026 02:14:57 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=A4=96=20fix(site/src/pages/AISettingsPag?= =?UTF-8?q?e):=20match=20Formik=20onSubmit=20args=20in=20Bedrock=20story?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The AddBedrockWithoutStaticCredentials interaction test asserted onSubmit was called with a single objectContaining argument, but Formik invokes onSubmit as (values, formikHelpers). The trailing helpers bag made toHaveBeenCalledWith never match, failing the storybook test deterministically on release/2.34 and breaking storybook CI for any PR targeting the branch. Match the second argument with expect.anything() so the assertion reflects Formik's actual call signature. --- .../ProvidersPage/components/ProviderForm.stories.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/site/src/pages/AISettingsPage/ProvidersPage/components/ProviderForm.stories.tsx b/site/src/pages/AISettingsPage/ProvidersPage/components/ProviderForm.stories.tsx index 0994ecb7a6b..f09d049e6df 100644 --- a/site/src/pages/AISettingsPage/ProvidersPage/components/ProviderForm.stories.tsx +++ b/site/src/pages/AISettingsPage/ProvidersPage/components/ProviderForm.stories.tsx @@ -93,6 +93,9 @@ export const AddBedrockWithoutStaticCredentials: Story = { accessKey: "", accessKeySecret: "", }), + // Formik invokes onSubmit as (values, formikHelpers), so the + // second argument must be matched for the assertion to pass. + expect.anything(), ), ); },