-
Notifications
You must be signed in to change notification settings - Fork 66
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
Update button package test harnesses #2726
Conversation
🦋 Changeset detectedLatest commit: d2fed88 The changes in this PR will be included in the next version bump. This PR includes changesets to release 28 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Size Change: +138 B (+0.01%) Total Size: 1.4 MB
ℹ️ View Unchanged
|
7956978
to
8573d3a
Compare
.changeset/late-chefs-build.md
Outdated
'@lg-tools/test-harnesses': minor | ||
--- | ||
|
||
Export `queryByLgId` util |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Export findByLgId
, getByLgId
, queryByLgId
✍️ Proposed changes
This PR is an initial stab at addressing 2 issues with our current test harnesses approach demonstrated in
@leafygreen-ui/button
.findButton
andqueryButton
test utilsdata-lgid
prop does not propagate to nested elements in the root componentLGIDS_BUTTON
object (in other packages, this may be namedLGIDs
,LGIDS
, orLGIDS_*
) with agetLgIds
util which can be used to propagate/interpolate thedata-lgid
prop into all the other keysdata-lgid
on the root. If you consider select test utils, you can think about: how do you test for asserting a specific label or description is present when multipleSelect
instances are rendered?🎟 Jira ticket: Name of ticket
✅ Checklist
For bug fixes, new features & breaking changes
pnpm changeset
and documented my changes🧪 How to test changes