Repository navigation
Migrate devextreme-angular wrapper tests to vitest - #36262
Draft
GoodDayForSurf wants to merge 6 commits into
Draft
GoodDayForSurf wants to merge 6 commits into
GoodDayForSurf wants to merge 6 commits into
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The Vite runtime path does not emit constructor metadata, preventing Angular from resolving JIT test dependencies and stopping affected tests before they reach their assertions.
1 open issue
1 file not reviewed
pnpm-lock.yaml: Generated file
What changed in this PR
Migrates DevExtreme’s Angular wrapper tests from Karma/Jasmine to Vitest browser mode, with Nx targets for client, server, hydration, and zone/zoneless environments.
Changes:
- Adds Vitest browser configuration and Angular test setup.
- Converts spies, timers, asynchronous tests, and typings to Vitest.
- Removes Karma/Webpack test infrastructure and updates dependencies and Nx targets.
| File | Description |
|---|---|
pnpm-lock.yaml |
Updates test dependencies and resolved packages. |
packages/nx-infra-plugin/src/executors/karma-multi-env/schema.ts |
Removes Karma executor option types. |
packages/nx-infra-plugin/src/executors/karma-multi-env/schema.json |
Removes Karma executor validation schema. |
packages/nx-infra-plugin/src/executors/karma-multi-env/schema.d.ts |
Removes Karma executor declarations. |
packages/nx-infra-plugin/src/executors/karma-multi-env/karma.types.ts |
Removes Karma environment mappings. |
packages/nx-infra-plugin/src/executors/karma-multi-env/karma-utils.ts |
Removes Karma loading utilities. |
packages/nx-infra-plugin/src/executors/karma-multi-env/karma-multi-env.impl.ts |
Removes multi-environment Karma execution. |
packages/nx-infra-plugin/src/executors/karma-multi-env/executor.ts |
Removes the Karma executor entry point. |
packages/nx-infra-plugin/src/executors/karma-multi-env/executor.spec.ts |
Removes retired executor tests. |
packages/nx-infra-plugin/package.json |
Removes the Karma peer dependency. |
packages/nx-infra-plugin/executors.json |
Unregisters the Karma executor. |
packages/devextreme-angular/webpack.test.js |
Removes Webpack test configuration. |
packages/devextreme-angular/vitest.config.mts |
Configures browser projects, package resolution, and reports. |
packages/devextreme-angular/tsconfig.tests.json |
Includes Vitest setup in type checking. |
packages/devextreme-angular/tsconfig.json |
Replaces Jasmine globals with Vitest typings. |
packages/devextreme-angular/tests/vitest/zone.ts |
Loads Zone.js testing support. |
packages/devextreme-angular/tests/vitest/setup.zoneless.ts |
Initializes zoneless browser tests. |
packages/devextreme-angular/tests/vitest/setup.server.ts |
Initializes zone-based server tests. |
packages/devextreme-angular/tests/vitest/setup.server-zoneless.ts |
Initializes zoneless server tests. |
packages/devextreme-angular/tests/vitest/setup.client.ts |
Initializes zone-based browser tests. |
packages/devextreme-angular/tests/vitest/init-test-bed.ts |
Centralizes Angular test environment initialization. |
packages/devextreme-angular/tests/vitest/common.ts |
Loads reflection support and Angular’s compiler. |
packages/devextreme-angular/tests/src/zone-modes/change-detection.spec.ts |
Migrates change-detection spies. |
packages/devextreme-angular/tests/src/ui/tag-box.spec.ts |
Migrates event-handler spies. |
packages/devextreme-angular/tests/src/ui/select-box.spec.ts |
Removes obsolete assertion type suppressions. |
packages/devextreme-angular/tests/src/ui/memory-leak.spec.ts |
Uses Vitest suite timeout configuration. |
packages/devextreme-angular/tests/src/ui/list.spec.ts |
Migrates spies and call-history assertions. |
packages/devextreme-angular/tests/src/ui/form.spec.ts |
Migrates option-reset spies. |
packages/devextreme-angular/tests/src/ui/data-grid.spec.ts |
Migrates timers, spies, asynchronous tests, and timeouts. |
packages/devextreme-angular/tests/src/ui/data-grid.legacy.spec.ts |
Migrates legacy grid tests to Vitest APIs. |
packages/devextreme-angular/tests/src/ui/custom-value-accessor-implementation.spec.ts |
Migrates the form-change callback mock. |
packages/devextreme-angular/tests/src/ui/chart.spec.ts |
Migrates chart spies and timers. |
packages/devextreme-angular/tests/src/server/hydration.spec.ts |
Migrates console spies and recreates them per test. |
packages/devextreme-angular/tests/src/http/ajax.spec.ts |
Migrates HTTP mocks, asynchronous tests, and timeout settings. |
packages/devextreme-angular/tests/src/http/ajax-bootstrap-interceptors.spec.ts |
Migrates interceptor spies and asynchronous tests. |
packages/devextreme-angular/tests/src/helpers/zone-mode.ts |
Uses Vitest’s conditional test skipping. |
packages/devextreme-angular/tests/src/core/nested-option.spec.ts |
Migrates nested-option callback spies. |
packages/devextreme-angular/tests/src/core/events-strategy.spec.ts |
Replaces Jasmine event-handler mocks. |
packages/devextreme-angular/tests/src/core/deprecated-config-warning.spec.ts |
Migrates warning spies and mock typings. |
packages/devextreme-angular/tests/src/core/component.spec.ts |
Migrates component event and lifecycle spies. |
packages/devextreme-angular/tests/src/core/angular-integration.spec.ts |
Migrates the integration injection spy. |
packages/devextreme-angular/project.json |
Replaces Karma targets with Vitest and separate type checking. |
packages/devextreme-angular/package.json |
Replaces legacy test dependencies with Vitest and Playwright. |
packages/devextreme-angular/karma.zoneless.test.shim.js |
Removes the zoneless browser bootstrap. |
packages/devextreme-angular/karma.zoneless-testing.module.js |
Removes the Karma zoneless testing module. |
packages/devextreme-angular/karma.zone.test.shim.js |
Removes the zone-mode test bootstrap. |
packages/devextreme-angular/karma.zone-testing.module.js |
Removes the Karma zone testing module. |
packages/devextreme-angular/karma.zone-polyfills.test.shim.js |
Removes the Karma Zone.js bootstrap. |
packages/devextreme-angular/karma.test.shim.js |
Removes the client test bootstrap. |
packages/devextreme-angular/karma.server.test.shim.js |
Removes the server test bootstrap. |
packages/devextreme-angular/karma.server-zoneless.test.shim.js |
Removes the zoneless server bootstrap. |
packages/devextreme-angular/karma.hydration.test.shim.js |
Removes the hydration test bootstrap. |
packages/devextreme-angular/karma.hydration-zoneless.test.shim.js |
Removes the zoneless hydration bootstrap. |
packages/devextreme-angular/karma.conf.js |
Removes Karma browser and reporter configuration. |
packages/devextreme-angular/karma.common.test.shim.js |
Removes shared Karma initialization and polyfills. |
packages/devextreme-angular/.gitignore |
Ignores Vitest’s XML report. |
.github/copilot-instructions.md |
Updates the documented Angular test framework. |
Review effort: Balanced
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

No description provided.