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

Support read only filesystem #5227

Closed
4 tasks done
MarcelCoding opened this issue Feb 17, 2024 · 2 comments
Closed
4 tasks done

Support read only filesystem #5227

MarcelCoding opened this issue Feb 17, 2024 · 2 comments

Comments

@MarcelCoding
Copy link

Clear and concise description of the problem

I use nixos, where build have a kind of read only file system. (only special folders, e.g. node_modules) Therefore they can not be written to.

The unfortunate is, that vitest has successfully executed all test, and is therefore "finished". Instead of just exiting, it tries to write to node_modules...
image

Suggested solution

Add an option to run in read only mode, where vitetest does not tries to write to disk.

Alternative

No response

Additional context

No response

Validations

@hi-ogawa
Copy link
Contributor

hi-ogawa commented Feb 18, 2024

Did you try --cache=false or changing cache.dir? https://vitest.dev/config/#cache

Also Vite/Vitest might write to node_modules/.vite, which can be changed by https://vitest.dev/config/#server-deps-cachedir

Other than node_modules, there could be one more source of file writing for Vite config loading #4901

@MarcelCoding
Copy link
Author

Thanks, setting --cache=false worked. Sorry, I did not find it in the docs.

@github-actions github-actions bot locked and limited conversation to collaborators Mar 4, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants