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

Migrate frontend test framework from Karma to Jest #2995

Draft
wants to merge 34 commits into
base: master
Choose a base branch
from

Conversation

Yicong-Huang
Copy link
Collaborator

@Yicong-Huang Yicong-Huang commented Nov 4, 2024

As Karma has been deprecated since April 2023, Karma and Angular is recommending developers to try and migrate to Jest.

This PR intends to the migration from Karma to Jest. It contains the following changes:

  • 1. removal of karma-related packages and configurations.
  • 2. removal of jasmine
  • 3. setup Jest and replace ng test entry point.
  • 4. removal of empty test cases (empty test file and tests without it entries).
  • 5. ignore transformation of ESM modules.
  • 6. migrating jasmine.Spy to Jest.Spy.
  • 7. fixing wrong tests cases, e.g., incorrect import of HttpClient.

# Conflicts:
#	core/gui/karma.conf.js
#	core/gui/package.json
#	core/gui/src/app/dashboard/component/user/filters/filters.component.spec.ts
#	core/gui/src/app/dashboard/component/user/list-item/list-item.component.ts
#	core/gui/src/app/dashboard/component/user/user-project/user-project-list-item/user-project-list-item.component.spec.ts
#	core/gui/src/app/hub/service/workflow/hub-workflow.service.ts
#	core/gui/src/app/workspace/component/workspace.component.ts
#	core/gui/src/test.ts
#	core/gui/yarn.lock
@Yicong-Huang Yicong-Huang marked this pull request as draft November 5, 2024 06:00
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.

1 participant