Skip to content

Migrate Label.test.tsx from Jest to Vitest #6301

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

liuliu-dev
Copy link
Contributor

This PR migrates the Label.test.tsx file from Jest to Vitest.

@Copilot Copilot AI review requested due to automatic review settings July 7, 2025 21:31
@liuliu-dev liuliu-dev requested a review from a team as a code owner July 7, 2025 21:31
@liuliu-dev liuliu-dev requested a review from joshblack July 7, 2025 21:31
Copy link

changeset-bot bot commented Jul 7, 2025

⚠️ No Changeset found

Latest commit: 74ede36

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR migrates the Label.test.tsx file from Jest to Vitest as part of the design system's testing framework transition. The migration includes updating import statements, simplifying test code, and configuring both test runners appropriately.

  • Updates test file to use Vitest imports and syntax
  • Adds Label tests to Vitest browser configuration
  • Excludes Label tests from Jest configuration to prevent duplicate execution

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
packages/react/src/Label/Label.test.tsx Migrates test imports to Vitest and simplifies test implementation
packages/react/vitest.config.browser.mts Adds Label test files to Vitest browser test inclusion pattern
packages/react/jest.config.js Excludes Label test directory from Jest execution
Comments suppressed due to low confidence (1)

packages/react/src/Label/Label.test.tsx:25

  • The axe accessibility test was removed during migration, which reduces test coverage for accessibility compliance. Consider adding equivalent accessibility tests using Vitest or ensure these are covered elsewhere in the test suite.
})

Copy link
Contributor

github-actions bot commented Jul 7, 2025

👋 Hi, this pull request contains changes to the source code that github/github depends on. If you are GitHub staff, we recommend testing these changes with github/github using the integration workflow. Thanks!

@github-actions github-actions bot added the integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm label Jul 7, 2025
@liuliu-dev liuliu-dev added the skip changeset This change does not need a changelog label Jul 7, 2025
Copy link
Contributor

github-actions bot commented Jul 7, 2025

size-limit report 📦

Path Size
packages/react/dist/browser.esm.js 92.02 KB (0%)
packages/react/dist/browser.umd.js 92.23 KB (0%)

Copy link
Member

@joshblack joshblack left a comment

Choose a reason for hiding this comment

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

Woo! Thanks for this 🥳

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm skip changeset This change does not need a changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants