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

[Visual testing]: Add visual tests for KCheckbox #925

Open
AlexVelezLl opened this issue Feb 4, 2025 · 2 comments
Open

[Visual testing]: Add visual tests for KCheckbox #925

AlexVelezLl opened this issue Feb 4, 2025 · 2 comments
Assignees
Labels
Component: KCheckbox help wanted Open source contributors welcome type: task Something that needs to be done Visual testing

Comments

@AlexVelezLl
Copy link
Member

🌱 Are you new to the codebase? Welcome! Please see the contributing guidelines.

Context

We recently introduced a new visual testing system in KDS to prevent visual regressions and ensure UI consistency, and we want to start populating our KDS components with visual tests.

If you are not familiar yet with our visual testing system. Please refer to our Visual Testing Guide. You can also check the existing tests for KButton as an example.

Additionally, see the KCheckbox documentation for reference.

Desired behavior

KCheckbox should have visual tests to cover at least these snapshots:

  • KCheckbox deselected
  • KCheckbox indeterminate
  • KCheckbox selected
  • KCheckbox deselected disabled
  • KCheckbox indeterminate disabled
  • KCheckbox selected disabled
  • KCheckbox without label (with showLabel=false)
  • KCheckbox using the default slot to set the label.
  • KCheckbox with description

Note

Since we currently dont have a test file for KCheckbox. Please move the current KCheckbox.vue file to be a folder KCheckbox/index.vue and create the test file in KCheckbox/__tests__/KCheckbox.spec.js

Acceptance criteria

  • A new visual test suite is created for KCheckbox.
  • The test includes all required snapshots.
  • The test runs successfully and captures the expected snapshots.
@AlexVelezLl AlexVelezLl added Component: KCheckbox help wanted Open source contributors welcome type: task Something that needs to be done Visual testing labels Feb 4, 2025
@you-think-you-know-me
Copy link

@AlexVelezLl I would love to work on this issue. Please assign this to me.

@AlexVelezLl
Copy link
Member Author

Hey @you-think-you-know-me! For sure! I will assign this to you, please let us know any question :).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: KCheckbox help wanted Open source contributors welcome type: task Something that needs to be done Visual testing
Projects
None yet
Development

No branches or pull requests

2 participants