Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Coachmark (v8): convert tests to use testing-library #22242

Conversation

TristanWatanabe
Copy link
Member

Current Behavior

  • v8 Coachmark tests don't use testing-library

New Behavior

  • Convert Coachmark to fully use testing-library

Related Issue(s)

part of #21663

);

const coachmark = getByRole('dialog', { hidden: true });
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needed hidden:true option since dialog role is inaccessible here because the element containing that role has a parent wrapper with role=presentation when the Coachmark is not collapsed.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting, I wonder if that's an actual a11y problem? Regardless would be good to note that in a comment in the file.

);

const coachmark = getByRole('dialog', { hidden: true });
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

@codesandbox-ci
Copy link

codesandbox-ci bot commented Mar 29, 2022

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 557da66:

Sandbox Source
@fluentui/react 8 starter Configuration
@fluentui/react-components 9 starter Configuration

@size-auditor
Copy link

size-auditor bot commented Mar 29, 2022

Asset size changes

Size Auditor did not detect a change in bundle size for any component!

Baseline commit: 062d979198fe559cb476660fdeb4d94a6e2d09cc (build)

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 29, 2022

📊 Bundle size report

🤖 This report was generated against 062d979198fe559cb476660fdeb4d94a6e2d09cc

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 29, 2022

Perf Analysis (@fluentui/react)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
BaseButton mount 1072 1055 5000
Breadcrumb mount 2912 2921 1000
Checkbox mount 1715 1731 5000
CheckboxBase mount 1456 1499 5000
ChoiceGroup mount 5263 5415 5000
ComboBox mount 1043 1187 1000
CommandBar mount 11140 11087 1000
ContextualMenu mount 12365 12526 1000
DefaultButton mount 1337 1327 5000
DetailsRow mount 4245 4268 5000
DetailsRowFast mount 4379 4252 5000
DetailsRowNoStyles mount 4133 4078 5000
Dialog mount 2363 2385 1000
DocumentCardTitle mount 164 184 1000
Dropdown mount 3651 3722 5000
FocusTrapZone mount 1922 1924 5000
FocusZone mount 1924 1906 5000
IconButton mount 1950 2096 5000
Label mount 396 399 5000
Layer mount 3292 3329 5000
Link mount 519 558 5000
MenuButton mount 1738 1727 5000
MessageBar mount 2252 2346 5000
Nav mount 3726 3655 1000
OverflowSet mount 1260 1207 5000
Panel mount 2308 2354 1000
Persona mount 1165 1120 1000
Pivot mount 1558 1609 1000
PrimaryButton mount 1499 1470 5000
Rating mount 8908 8921 5000
SearchBox mount 1556 1528 5000
Shimmer mount 2819 2860 5000
Slider mount 2174 2160 5000
SpinButton mount 5531 5549 5000
Spinner mount 459 478 5000
SplitButton mount 3526 3565 5000
Stack mount 599 586 5000
StackWithIntrinsicChildren mount 2843 2699 5000
StackWithTextChildren mount 6318 6230 5000
SwatchColorPicker mount 12608 12881 5000
TagPicker mount 2979 3058 5000
TeachingBubble mount 106448 108021 5000
Text mount 509 503 5000
TextField mount 1622 1609 5000
ThemeProvider mount 1270 1265 5000
ThemeProvider virtual-rerender 685 708 5000
ThemeProvider virtual-rerender-with-unmount 2046 2052 5000
Toggle mount 888 897 5000
buttonNative mount 146 165 5000

@TristanWatanabe TristanWatanabe marked this pull request as ready for review March 30, 2022 00:25
@TristanWatanabe TristanWatanabe requested review from a team and leddie24 as code owners March 30, 2022 00:25
);

const coachmark = getByRole('dialog', { hidden: true });
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting, I wonder if that's an actual a11y problem? Regardless would be good to note that in a comment in the file.

@TristanWatanabe TristanWatanabe merged commit 50b0659 into microsoft:master Mar 30, 2022
@TristanWatanabe TristanWatanabe deleted the coachmark-convert-to-testing-library branch March 30, 2022 17:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants