Increase storybook pages coverage (#4885)
On FE: - refreshing metadata mocks - updating jest tests - fixing storybook pages coverage - fixing storybook modules coverage
This commit is contained in:
@ -60,7 +60,11 @@ export const MonthAndYearDropdown = ({
|
||||
}}
|
||||
dropdownPlacement="bottom-start"
|
||||
clickableComponent={
|
||||
<LightIconButton Icon={IconCalendarDue} size="medium" />
|
||||
<LightIconButton
|
||||
testId="month-and-year-dropdown"
|
||||
Icon={IconCalendarDue}
|
||||
size="medium"
|
||||
/>
|
||||
}
|
||||
dropdownComponents={
|
||||
<DropdownMenuItemsContainer>
|
||||
|
||||
@ -23,11 +23,16 @@ export const WithOpenMonthSelect: Story = {
|
||||
play: async ({ canvasElement }) => {
|
||||
const canvas = within(canvasElement);
|
||||
|
||||
const monthSelect = canvas.getByText('January');
|
||||
const monthAndYearButton = await canvas.findByTestId(
|
||||
'month-and-year-dropdown',
|
||||
);
|
||||
|
||||
await userEvent.click(monthAndYearButton);
|
||||
|
||||
const monthSelect = await canvas.findByText('January');
|
||||
|
||||
await userEvent.click(monthSelect);
|
||||
|
||||
expect(canvas.getAllByText('January')).toHaveLength(2);
|
||||
[
|
||||
'February',
|
||||
'March',
|
||||
|
||||
Reference in New Issue
Block a user