From 8c8580eadb4dbccfd3c0b722ea5cc432e9ac5ab3 Mon Sep 17 00:00:00 2001 From: Elaina Lee Date: Thu, 27 Aug 2026 15:54:10 -0700 Subject: [PATCH] test(designer): update Fluent icon snapshot baselines Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../__tests__/TimelineHeader.test.tsx | 6 +- .../TimelineButtons.test.tsx.snap | 372 +-------- .../TimelineContent.test.tsx.snap | 88 +-- .../__snapshots__/TimelineGroup.test.tsx.snap | 217 +---- .../TimelineHeader.test.tsx.snap | 85 +- .../collapseMenuItem.spec.tsx.snap | 62 +- .../__snapshots__/pinMenuItem.spec.tsx.snap | 62 +- .../agentChatHeader.spec.tsx.snap | 217 +---- .../__snapshots__/inputsPanel.spec.tsx.snap | 310 +------- .../__snapshots__/outputsPanel.spec.tsx.snap | 744 ++---------------- .../advancedSettingsMessage.spec.tsx.snap | 32 +- .../settingsection.spec.tsx.snap | 2 +- 12 files changed, 233 insertions(+), 1964 deletions(-) diff --git a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/TimelineHeader.test.tsx b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/TimelineHeader.test.tsx index c6e70478424..bb1f77bdb40 100644 --- a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/TimelineHeader.test.tsx +++ b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/TimelineHeader.test.tsx @@ -83,9 +83,11 @@ describe('TimelineHeader', () => { }); it('should render timeline icon in both expanded and collapsed states', () => { + const isHostElement = (instance: { type: unknown }) => typeof instance.type === 'string'; + // Test expanded const expandedComponent = renderWithIntl(defaultProps); - const expandedIcons = expandedComponent.root.findAllByProps({ className: 'timeline-icon' }); + const expandedIcons = expandedComponent.root.findAllByProps({ className: 'timeline-icon' }).filter(isHostElement); expect(expandedIcons).toHaveLength(1); // Test collapsed @@ -93,7 +95,7 @@ describe('TimelineHeader', () => { ...defaultProps, isExpanded: false, }); - const collapsedIcons = collapsedComponent.root.findAllByProps({ className: 'timeline-icon' }); + const collapsedIcons = collapsedComponent.root.findAllByProps({ className: 'timeline-icon' }).filter(isHostElement); expect(collapsedIcons).toHaveLength(1); }); diff --git a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineButtons.test.tsx.snap b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineButtons.test.tsx.snap index 0bcc9f45cfa..b5e8caa8074 100644 --- a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineButtons.test.tsx.snap +++ b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineButtons.test.tsx.snap @@ -13,34 +13,9 @@ exports[`TimelineButtons > should render collapsed (not expanded) 1`] = ` - - - - - - + @@ -98,34 +48,9 @@ exports[`TimelineButtons > should render with default props 1`] = ` - - - - - - + Previous task @@ -138,34 +63,9 @@ exports[`TimelineButtons > should render with default props 1`] = ` - - - - - - + Next task @@ -185,34 +85,9 @@ exports[`TimelineButtons > should render with disabled buttons when fetching rep - - - - - - + Previous task @@ -225,34 +100,9 @@ exports[`TimelineButtons > should render with disabled buttons when fetching rep - - - - - - + Next task @@ -272,34 +122,9 @@ exports[`TimelineButtons > should render with disabled buttons when no repetitio - - - - - - + Previous task @@ -312,34 +137,9 @@ exports[`TimelineButtons > should render with disabled buttons when no repetitio - - - - - - + Next task @@ -359,34 +159,9 @@ exports[`TimelineButtons > should render with disabled next button at last task - - - - - - + Previous task @@ -399,34 +174,9 @@ exports[`TimelineButtons > should render with disabled next button at last task - - - - - - + Next task @@ -446,34 +196,9 @@ exports[`TimelineButtons > should render with disabled previous button at first - - - - - - + Previous task @@ -486,34 +211,9 @@ exports[`TimelineButtons > should render with disabled previous button at first - - - - - - + Next task diff --git a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineContent.test.tsx.snap b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineContent.test.tsx.snap index be4da623a7f..b939127e101 100644 --- a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineContent.test.tsx.snap +++ b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineContent.test.tsx.snap @@ -107,20 +107,10 @@ exports[`TimelineContent > should render error carets for failed repetitions 1`]
- - - +
@@ -198,11 +188,8 @@ exports[`TimelineContent > should render no repetitions state 1`] = ` } } > - should render no repetitions state 1`] = ` "width": "30px", } } - viewBox="0 0 20 20" - width="1em" - xmlns="http://www.w3.org/2000/svg" - > - - + /> should render no repetitions state when collapsed 1`] } } > - should render no repetitions state when collapsed 1`] "width": "30px", } } - viewBox="0 0 20 20" - width="1em" - xmlns="http://www.w3.org/2000/svg" - > - - + /> `; @@ -340,20 +308,10 @@ exports[`TimelineContent > should render with default props 1`] = ` >
- - - +
`; @@ -489,20 +447,10 @@ exports[`TimelineContent > should render with multiple task groups 1`] = `
- - - +
`; diff --git a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineGroup.test.tsx.snap b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineGroup.test.tsx.snap index 5bef0c7cde1..2dd983efd62 100644 --- a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineGroup.test.tsx.snap +++ b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineGroup.test.tsx.snap @@ -23,34 +23,9 @@ exports[`TimelineGroup > should render as collapsed group initially 1`] = ` - - - - - - + Task #1 @@ -80,34 +55,9 @@ exports[`TimelineGroup > should render as expanded group when taskId matches tra - - - - - - + Task #1 @@ -199,34 +149,9 @@ exports[`TimelineGroup > should render with default props when timeline is expan - - - - - - + Task #1 @@ -256,34 +181,9 @@ exports[`TimelineGroup > should render with different task number 1`] = ` - - - - - - + Task #6 @@ -313,34 +213,9 @@ exports[`TimelineGroup > should render with empty repetitions 1`] = ` - - - - - - + Task #1 @@ -370,34 +245,9 @@ exports[`TimelineGroup > should render with no selected repetition 1`] = ` - - - - - - + Task #1 @@ -427,34 +277,9 @@ exports[`TimelineGroup > should render with single repetition 1`] = ` - - - - - - + Task #1 diff --git a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineHeader.test.tsx.snap b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineHeader.test.tsx.snap index 0345f9f4030..25b7099d475 100644 --- a/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineHeader.test.tsx.snap +++ b/libs/designer/src/lib/ui/MonitoringTimeline/__tests__/__snapshots__/TimelineHeader.test.tsx.snap @@ -11,20 +11,10 @@ exports[`TimelineHeader > should not render title text when collapsed 1`] = ` } } > - - - +
`; @@ -39,20 +29,10 @@ exports[`TimelineHeader > should render when collapsed 1`] = ` } } > - - - + `; @@ -68,20 +48,10 @@ exports[`TimelineHeader > should render with default props when expanded 1`] = ` } } > - - - + should render with default props when expanded 1`] = ` - - - - - - + diff --git a/libs/designer/src/lib/ui/menuItems/__test__/__snapshots__/collapseMenuItem.spec.tsx.snap b/libs/designer/src/lib/ui/menuItems/__test__/__snapshots__/collapseMenuItem.spec.tsx.snap index ff1f85bf58a..692e7dd2232 100644 --- a/libs/designer/src/lib/ui/menuItems/__test__/__snapshots__/collapseMenuItem.spec.tsx.snap +++ b/libs/designer/src/lib/ui/menuItems/__test__/__snapshots__/collapseMenuItem.spec.tsx.snap @@ -14,34 +14,9 @@ exports[`lib/ui/menuItems/collapseMenuItem > should render correctly when isColl - - - - - - + should render correctly when isColl - - - - - - + should render for actions if pinned=fals - - - - - - + should render for actions if pinned=true - - - - - - + renders correctly and matches snapshot when showing s - - - - - - + @@ -194,34 +119,9 @@ exports[`AgentChatHeader > renders correctly and matches snapshot with dark mode - - - - - - + @@ -308,34 +183,9 @@ exports[`AgentChatHeader > renders correctly when dark mode is on 1`] = ` - - - - - - + diff --git a/libs/designer/src/lib/ui/panel/nodeDetailsPanel/tabs/monitoringTab/__tests__/__snapshots__/inputsPanel.spec.tsx.snap b/libs/designer/src/lib/ui/panel/nodeDetailsPanel/tabs/monitoringTab/__tests__/__snapshots__/inputsPanel.spec.tsx.snap index 44d1aabb0ca..0d151c01034 100644 --- a/libs/designer/src/lib/ui/panel/nodeDetailsPanel/tabs/monitoringTab/__tests__/__snapshots__/inputsPanel.spec.tsx.snap +++ b/libs/designer/src/lib/ui/panel/nodeDetailsPanel/tabs/monitoringTab/__tests__/__snapshots__/inputsPanel.spec.tsx.snap @@ -20,34 +20,9 @@ exports[`InputsPanel > should render error state 1`] = ` - - + Inputs @@ -59,34 +34,9 @@ exports[`InputsPanel > should render error state 1`] = ` - - + @@ -120,34 +70,9 @@ exports[`InputsPanel > should render error state 1`] = ` - - + @@ -199,34 +124,9 @@ exports[`InputsPanel > should render loading state 1`] = ` - - + Inputs @@ -238,34 +138,9 @@ exports[`InputsPanel > should render loading state 1`] = ` - - + @@ -299,34 +174,9 @@ exports[`InputsPanel > should render loading state 1`] = ` - - + @@ -378,34 +228,9 @@ exports[`InputsPanel > should render the InputsPanel with inputs 1`] = ` - - + Inputs @@ -417,34 +242,9 @@ exports[`InputsPanel > should render the InputsPanel with inputs 1`] = ` - - + @@ -478,34 +278,9 @@ exports[`InputsPanel > should render the InputsPanel with inputs 1`] = ` - - + @@ -557,34 +332,9 @@ exports[`InputsPanel > should render the InputsPanel with no inputs 1`] = ` - - + Inputs diff --git a/libs/designer/src/lib/ui/panel/nodeDetailsPanel/tabs/monitoringTab/__tests__/__snapshots__/outputsPanel.spec.tsx.snap b/libs/designer/src/lib/ui/panel/nodeDetailsPanel/tabs/monitoringTab/__tests__/__snapshots__/outputsPanel.spec.tsx.snap index 6e2780d24fb..666d3b70e0c 100644 --- a/libs/designer/src/lib/ui/panel/nodeDetailsPanel/tabs/monitoringTab/__tests__/__snapshots__/outputsPanel.spec.tsx.snap +++ b/libs/designer/src/lib/ui/panel/nodeDetailsPanel/tabs/monitoringTab/__tests__/__snapshots__/outputsPanel.spec.tsx.snap @@ -23,34 +23,9 @@ exports[`OutputsPanel > Should render OutputsPanel with error state 1`] = ` - - + Outputs @@ -62,34 +37,9 @@ exports[`OutputsPanel > Should render OutputsPanel with error state 1`] = ` - - + @@ -123,34 +73,9 @@ exports[`OutputsPanel > Should render OutputsPanel with error state 1`] = ` - - + @@ -200,34 +125,9 @@ exports[`OutputsPanel > Should render OutputsPanel with error state 1`] = ` - - + Outputs @@ -239,34 +139,9 @@ exports[`OutputsPanel > Should render OutputsPanel with error state 1`] = ` - - + @@ -300,34 +175,9 @@ exports[`OutputsPanel > Should render OutputsPanel with error state 1`] = ` - - + @@ -434,34 +284,9 @@ exports[`OutputsPanel > Should render OutputsPanel with loading state 1`] = ` - - + Outputs @@ -473,34 +298,9 @@ exports[`OutputsPanel > Should render OutputsPanel with loading state 1`] = ` - - + @@ -534,34 +334,9 @@ exports[`OutputsPanel > Should render OutputsPanel with loading state 1`] = ` - - + @@ -611,34 +386,9 @@ exports[`OutputsPanel > Should render OutputsPanel with loading state 1`] = ` - - + Outputs @@ -650,34 +400,9 @@ exports[`OutputsPanel > Should render OutputsPanel with loading state 1`] = ` - - + @@ -711,34 +436,9 @@ exports[`OutputsPanel > Should render OutputsPanel with loading state 1`] = ` - - + @@ -845,34 +545,9 @@ exports[`OutputsPanel > Should render OutputsPanel with no outputs 1`] = ` - - + Outputs @@ -922,34 +597,9 @@ exports[`OutputsPanel > Should render OutputsPanel with no outputs 1`] = ` - - + Outputs @@ -1056,34 +706,9 @@ exports[`OutputsPanel > Should render OutputsPanel with outputs 1`] = ` - - + Outputs @@ -1095,34 +720,9 @@ exports[`OutputsPanel > Should render OutputsPanel with outputs 1`] = ` - - + @@ -1156,34 +756,9 @@ exports[`OutputsPanel > Should render OutputsPanel with outputs 1`] = ` - - + @@ -1233,34 +808,9 @@ exports[`OutputsPanel > Should render OutputsPanel with outputs 1`] = ` - - + Outputs @@ -1272,34 +822,9 @@ exports[`OutputsPanel > Should render OutputsPanel with outputs 1`] = ` - - + @@ -1333,34 +858,9 @@ exports[`OutputsPanel > Should render OutputsPanel with outputs 1`] = ` - - + @@ -1584,34 +1084,9 @@ exports[`OutputsPanel > Should render OutputsPanel without uri 1`] = ` - - + Outputs @@ -1646,34 +1121,9 @@ exports[`OutputsPanel > Should render OutputsPanel without uri 1`] = ` - - + @@ -1723,34 +1173,9 @@ exports[`OutputsPanel > Should render OutputsPanel without uri 1`] = ` - - + Outputs @@ -1785,34 +1210,9 @@ exports[`OutputsPanel > Should render OutputsPanel without uri 1`] = ` - - + diff --git a/libs/designer/src/lib/ui/settings/__tests__/__snapshots__/advancedSettingsMessage.spec.tsx.snap b/libs/designer/src/lib/ui/settings/__tests__/__snapshots__/advancedSettingsMessage.spec.tsx.snap index 6d2962bc51b..099a977e2b2 100644 --- a/libs/designer/src/lib/ui/settings/__tests__/__snapshots__/advancedSettingsMessage.spec.tsx.snap +++ b/libs/designer/src/lib/ui/settings/__tests__/__snapshots__/advancedSettingsMessage.spec.tsx.snap @@ -19,36 +19,10 @@ exports[`AdvancedSettingsMessage Component > should render correctly and match s target="_blank" > Guideline for agent advanced parameters - - + /> `; diff --git a/libs/designer/src/lib/ui/settings/__tests__/__snapshots__/settingsection.spec.tsx.snap b/libs/designer/src/lib/ui/settings/__tests__/__snapshots__/settingsection.spec.tsx.snap index ad33827afc7..013a2bd4bc3 100644 --- a/libs/designer/src/lib/ui/settings/__tests__/__snapshots__/settingsection.spec.tsx.snap +++ b/libs/designer/src/lib/ui/settings/__tests__/__snapshots__/settingsection.spec.tsx.snap @@ -11,7 +11,7 @@ exports[`ui/settings/settingsection > should construct 1`] = ` appearance="subtle" aria-label="Collapsed Sample Setting Section, Select to expand" className="msla-setting-section-header" - icon={} + icon={} onClick={[Function]} > Sample Setting Section