Skip to content

Conversation

@AtofStryker
Copy link
Contributor

@AtofStryker AtofStryker commented Nov 3, 2025

  • Closes N/A

Additional details

Converts @cypress/webpack-dev-server tests to vitest. Additionally, the package now uses tsx to import ESM only packages into @cypress/webpack-dev-server, which is a CommonJS module. This is because the dynamic import code does not work properly within the vitest context. This change shouldn't be disruptive

Steps to test

How has the user experience changed?

PR Tasks


Note

Migrates @cypress/webpack-dev-server tests from Mocha/Chai/Sinon to Vitest and replaces dynamic import logic with tsx-based ESM imports (e.g., find-up, Angular CLI modules).

  • npm/webpack-dev-server
    • Testing: Migrate all tests to vitest; convert assertions/mocks; add vitest.config.ts; update scripts (test, test-debug).
    • ESM Imports: Remove src/dynamic-import.ts; use tsx/esm/api (tsImport) to load ESM-only modules like find-up and Angular CLI files; update angularHandler.ts and makeWebpackConfig.ts accordingly.
    • Tests/Fixtures: Update snapshots to Vitest format; adjust test utilities and timing; replace deprecated Mocha configs/support files.
    • Dependencies: Add vitest and tsx; drop Mocha/Chai/Sinon-related deps.
  • Docs
    • Update guides/esm-migration.md to mark npm/webpack-dev-server as completed in Phase 2.

Written by Cursor Bugbot for commit 4387f60. This will update automatically on new commits. Configure here.

@AtofStryker AtofStryker self-assigned this Nov 3, 2025
@cypress
Copy link

cypress bot commented Nov 3, 2025

cypress    Run #67132

Run Properties:  status check passed Passed #67132  •  git commit 404408e59d: chore: convert webpack-dev-server tests to vitest
Project cypress
Branch Review chore/webpack-dev-server-vitest
Run status status check passed Passed #67132
Run duration 10m 50s
Commit git commit 404408e59d: chore: convert webpack-dev-server tests to vitest
Committer Bill Glesias
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 1
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 703
View all changes introduced in this branch ↗︎
UI Coverage  38.03%
  Untested elements 132  
  Tested elements 81  
Accessibility  97.39%
  Failed rules  3 critical   7 serious   1 moderate   1 minor
  Failed elements 62  

@AtofStryker AtofStryker force-pushed the chore/webpack-dev-server-vitest branch from 0403e57 to 404408e Compare November 4, 2025 13:17
@AtofStryker AtofStryker changed the title chore (draft): convert webpack-dev-server tests to vitest misc (draft): convert @cypress/webpack-dev-server tests to vitest. Additionally, uses tsx to import ESM only packages into @cypress/webpack-dev-server Nov 4, 2025
@AtofStryker AtofStryker changed the title misc (draft): convert @cypress/webpack-dev-server tests to vitest. Additionally, uses tsx to import ESM only packages into @cypress/webpack-dev-server misc: convert @cypress/webpack-dev-server tests to vitest. Additionally, uses tsx to import ESM only packages into @cypress/webpack-dev-server Nov 4, 2025
@jennifer-shehane jennifer-shehane self-requested a review November 4, 2025 14:50
@AtofStryker AtofStryker merged commit c34e57b into develop Nov 6, 2025
6 of 7 checks passed
@AtofStryker AtofStryker deleted the chore/webpack-dev-server-vitest branch November 6, 2025 15:14
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.

3 participants