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

test(SecondaryButton): Enzyme->RTL - refactor out the render in setup #12805

Merged

Conversation

cknabe
Copy link
Contributor

@cknabe cknabe commented Dec 6, 2022

Relates to #12700

  • In the above PR, I applied a pattern to the SecondaryButton-test where I created a renderSecondaryButton method. This is not the correct style. A render method should just be declared in every test statement.
  • I also had removed the prefix.. and I think that may have been a bad decision. To keep consistency, I added that back in.
  • I attempted to run Abbey's script to generate the tests, but because this is an inherited button type, the script doesn't find 'propTypes' and does not run. Abbey's script is more for the parent button anyway.

@cknabe cknabe requested a review from a team as a code owner December 6, 2022 19:58
@cknabe cknabe changed the title test(SecondaryButton): refactor out the render in setup test(SecondaryButton): Enzyme->RTL - refactor out the render in setup Dec 6, 2022
@netlify
Copy link

netlify bot commented Dec 6, 2022

Deploy Preview for carbon-components-react ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 758a569
🔍 Latest deploy log https://app.netlify.com/sites/carbon-components-react/deploys/6391fd3f85424b0008541431
😎 Deploy Preview https://deploy-preview-12805--carbon-components-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@netlify
Copy link

netlify bot commented Dec 6, 2022

Deploy Preview for carbon-elements ready!

Name Link
🔨 Latest commit 758a569
🔍 Latest deploy log https://app.netlify.com/sites/carbon-elements/deploys/6391fd3fde2a130008d98760
😎 Deploy Preview https://deploy-preview-12805--carbon-elements.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

Copy link
Collaborator

@tw15egan tw15egan left a comment

Choose a reason for hiding this comment

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

Thanks for fixing that 🙏

@kodiakhq kodiakhq bot merged commit 0bdbce1 into carbon-design-system:main Dec 8, 2022
@carbon-bot
Copy link
Contributor

Hey there! v11.19.0 was just released that references this issue/PR.

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.

4 participants