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

Vitest #6326

Open
tisto opened this issue Sep 25, 2024 · 10 comments · May be fixed by #6605
Open

Vitest #6326

tisto opened this issue Sep 25, 2024 · 10 comments · May be fixed by #6605

Comments

@tisto
Copy link
Member

tisto commented Sep 25, 2024

PLIP (Plone Improvement Proposal)

Responsible Persons

Proposer: Víctor Fernandez de Alba (@sneridagh)

Seconder:

Abstract

Replace Jest with Vitest as the Volto unit test runner.

Motivation

Jest is showing its age compared to Vitest. Vitest is the unit test runner that uses Vite under the hood. It uses a zero configuration model, thanks to be Vite-based. It's faster as it is Vite who transpiles the code.

Assumptions

None.

Proposal & Implementation

Vitest shares the same syntax as they use Mocha/Chai we will have to adapt the test setup to meet Vitest requirements and move the mocks to the Vitest style, if needed.

Deliverables

Volto will be using Vitest instead of Jest for running tests.
Documentation on how to migrate projects and add-ons to use Vitest.
Documentation on Vitest.

Risks

None.

Participants

Open for volunteers. This could be easily a GSOC for next year.

@Abhishek-17h
Copy link
Contributor

I am working on this issue. It requires a systematic approach for migration, and I will provide regular updates on my progress.

@Abhishek-17h
Copy link
Contributor

I am halfway through the migration process and will raise a draft PR for corrections and suggestions.

@Shyam-Raghuwanshi
Copy link
Contributor

@stevepiercy we need to do more discussion on this or should i proceed?

@stevepiercy
Copy link
Collaborator

@Shyam-Raghuwanshi I don't know why you @ me. I'm not participating in this PLIP.

Please read and follow First-time contributors, especially Things not to do and Work with GitHub issues.

@Abhishek-17h
Copy link
Contributor

@Shyam-Raghuwanshi I am already working on it and u can take other issues that are open or not claimed to avoid any duplication and waste of effort.

@Shyam-Raghuwanshi
Copy link
Contributor

@Abhishek-17h you should make a draft pr

@stevepiercy
Copy link
Collaborator

@Abhishek-17h you should make a draft pr

They should have followed the advice in #6326 (comment). But since they did not follow that document and started work on this PLIP, publishing a draft PR is also a good suggestion. At least they would get feedback on whether they are on the right path, and possibly avoid wasting their time and effort.

I don't know how to help first-timers avoid spending time that might become a waste, other than what we have already set up. If you have other suggestions, please come to the Documentation channel in Discord, and let's chat.

@Abhishek-17h
Copy link
Contributor

I am halfway through the migration process and will raise a draft PR for corrections and suggestions.

@Shyam-Raghuwanshi yes, I will raise a draft PR for this soon and I already mentioned it.

@alihamza1221

This comment has been minimized.

@Abhishek-17h
Copy link
Contributor

@alihamza1221 hey , I am working on this issue actually over a month and volto is very large repo and migration is not straight forward and it takes time. I am not afraid of anything and U should understand if someone is working on some issue u should take another issue ,so it don't waste efforts of both contributors.In plone they don't assign issue, u have to claim it and work on that and that's what I am doing. Hope u have gone through plone's documentation and documents mentioned here

@Shyam-Raghuwanshi I don't know why you @ me. I'm not participating in this PLIP.

Please read and follow First-time contributors, especially Things not to do and Work with GitHub issues.

@Abhishek-17h Abhishek-17h linked a pull request Jan 21, 2025 that will close this issue
9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Status: No status
Development

Successfully merging a pull request may close this issue.

6 participants