I am writing tests for my REST API. I have unit tests and e2e tests( calls to endpoints without any mocking). I have an endpoint which adds notifications in queue. I am not sure how to test this or should I test this in e2e tests. One way I am thinking is to check db after the call was made to check if notification is there, but I don't think that's the best solution. I was also thinking to just check it in unit test. Any recommendations or ideas how to tackle this issue? What are the best practices?
Aucun commentaire:
Enregistrer un commentaire