Integration testing in React
You can view my app in my repository, make sure you're on the tests/vitest branch. The Problem I am trying to incorporate integration tests for my components. The thing is, in my app I always check if a user is authenticated. This happens in a component called AuthContext.tsx and it uses /auth/re and /auth/refresh-token to verify if a user is authenticated (if he has a valid token cookie). Now, I understood that in react-testing-library there is no way to use cookies, and there is no need to. I am very confused. Should I simulate exactly how my app works? Or just manipulate my components (i.e
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.