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

chore: improved data testing by ui and test id #7428

Merged
merged 2 commits into from
Aug 30, 2024

Conversation

jordanl17
Copy link
Member

@jordanl17 jordanl17 commented Aug 29, 2024

Description

Improves the options to find elements when testing dialogs; adds support to test by data-ui attr

What to review

  • Additional data-testids for the CTAs in dialog
  • new util test function byDataUi - which can be used as queryByDataUi/getAllByDataUi etc - allows for finding elements by their pre-existing data-ui attributes, rather than always having to add on data-testids

Testing

Neither of these are currently used in tests, however when content releases is merged they are employed there.
Additionally, this will help with testing across studio in some cases currently

Notes for release

N/A

Copy link

vercel bot commented Aug 29, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
page-building-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 29, 2024 10:28am
performance-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 29, 2024 10:28am
test-compiled-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 29, 2024 10:28am
test-next-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 29, 2024 10:28am
test-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 29, 2024 10:28am
1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
studio-workshop ⬜️ Ignored (Inspect) Visit Preview Aug 29, 2024 10:28am

Copy link
Contributor

No changes to documentation

Copy link
Contributor

github-actions bot commented Aug 29, 2024

Component Testing Report Updated Aug 29, 2024 10:30 AM (UTC)

❌ Failed Tests (1) -- expand for details
File Status Duration Passed Skipped Failed
comments/CommentInput.spec.tsx ✅ Passed (Inspect) 42s 15 0 0
formBuilder/ArrayInput.spec.tsx ✅ Passed (Inspect) 8s 3 0 0
formBuilder/inputs/PortableText/Annotations.spec.tsx ✅ Passed (Inspect) 29s 6 0 0
formBuilder/inputs/PortableText/copyPaste/CopyPaste.spec.tsx ✅ Passed (Inspect) 36s 11 7 0
formBuilder/inputs/PortableText/copyPaste/CopyPasteFields.spec.tsx ✅ Passed (Inspect) 0s 0 12 0
formBuilder/inputs/PortableText/Decorators.spec.tsx ✅ Passed (Inspect) 17s 6 0 0
formBuilder/inputs/PortableText/DisableFocusAndUnset.spec.tsx ✅ Passed (Inspect) 10s 3 0 0
formBuilder/inputs/PortableText/DragAndDrop.spec.tsx ✅ Passed (Inspect) 2m 34s 1 0 0
formBuilder/inputs/PortableText/FocusTracking.spec.tsx ✅ Passed (Inspect) 43s 15 0 0
formBuilder/inputs/PortableText/Input.spec.tsx ✅ Passed (Inspect) 1m 42s 21 0 0
formBuilder/inputs/PortableText/ObjectBlock.spec.tsx ✅ Passed (Inspect) 1m 14s 18 0 0
formBuilder/inputs/PortableText/PresenceCursors.spec.tsx ✅ Passed (Inspect) 9s 3 9 0
formBuilder/inputs/PortableText/RangeDecoration.spec.tsx ✅ Passed (Inspect) 25s 9 0 0
formBuilder/inputs/PortableText/Styles.spec.tsx ✅ Passed (Inspect) 18s 6 0 0
formBuilder/inputs/PortableText/Toolbar.spec.tsx ❌ Failed (Inspect) 1m 23s 20 0 1
formBuilder/tree-editing/TreeEditing.spec.tsx ✅ Passed (Inspect) 0s 0 3 0
formBuilder/tree-editing/TreeEditingNestedObjects.spec.tsx ✅ Passed (Inspect) 0s 0 3 0

Copy link
Contributor

@RitaDias RitaDias left a comment

Choose a reason for hiding this comment

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

LET'S GO JORDAN 🚀

Copy link
Contributor

@binoy14 binoy14 left a comment

Choose a reason for hiding this comment

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

Very nice! Thanks

@jordanl17 jordanl17 added this pull request to the merge queue Aug 30, 2024
Merged via the queue into next with commit deca138 Aug 30, 2024
42 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants