Environment plugin to enhance testing for prisma #2473
aiji42
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have created an environment plugin to improve the experience of testing with a combination of vitest and prisma.
vitest-environment-vprisma
It allows you to isolate each test case with a transaction and rollback after completion, giving you a safe and clean testing environment.
It can also be used with environment libraries officially supported by vitest, such as
jsdom
,happy-dom
, andedge-runtime
. So even if you are using Remix or Next.js and need to run both client-side and back-end tests, it is no problem.Please try it and let me know if you have any requests for improvement.
Beta Was this translation helpful? Give feedback.
All reactions