In this PR, 
- current basic E2E tests are fixed, and some were added, covering some
basic scenarios
- some tests avec been commented out, until we decide whether they are
worth fixing

The next steps are
- evaluate the flakiness of the tests. Once they've proved not to be
flaky, we should add more tests + re-write the current ones not using
aria-label (cf @lucasbordeau indication).
- We will add them back to the development flow
This commit is contained in:
Marie
2025-12-17 08:48:17 +01:00
committed by GitHub
parent 1cbbd04761
commit 0145920d7e
29 changed files with 783 additions and 447 deletions
@@ -23,6 +23,8 @@ export type LightIconButtonGroupProps = Pick<
accent?: LightIconButtonProps['accent'];
onClick?: (event: MouseEvent<any>) => void;
disabled?: boolean;
ariaLabel?: string;
dataTestId?: string;
}[];
};
@@ -32,26 +34,30 @@ export const LightIconButtonGroup = ({
className,
}: LightIconButtonGroupProps) => (
<StyledLightIconButtonGroupContainer className={className}>
{iconButtons.map(({ Wrapper, Icon, accent, onClick }, index) => {
const iconButton = (
<LightIconButton
key={`light-icon-button-${index}`}
Icon={Icon}
accent={accent}
disabled={!onClick}
onClick={onClick}
size={size}
/>
);
{iconButtons.map(
({ Wrapper, Icon, accent, onClick, ariaLabel, dataTestId }, index) => {
const iconButton = (
<LightIconButton
key={`light-icon-button-${index}`}
Icon={Icon}
accent={accent}
disabled={!onClick}
onClick={onClick}
size={size}
aria-label={ariaLabel}
testId={dataTestId}
/>
);
return Wrapper ? (
<Wrapper
key={`light-icon-button-wrapper-${index}`}
iconButton={iconButton}
/>
) : (
iconButton
);
})}
return Wrapper ? (
<Wrapper
key={`light-icon-button-wrapper-${index}`}
iconButton={iconButton}
/>
) : (
iconButton
);
},
)}
</StyledLightIconButtonGroupContainer>
);