Cypress intercept throwing "jwt malformed" error on unauthorized queries #29031
Unanswered
MohsinGhani
asked this question in
Questions and Help
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Issue Description
When using Cypress intercept to handle unauthorized queries, an error "jwt malformed" is thrown. This issue arises specifically when intercepting unauthorized queries. It's worth noting that authorized queries, after logging in, function as expected without throwing errors. Additionally, manual testing has confirmed that the intercept functionality works as intended.
Steps to Reproduce
Expected Behavior
Unauthorized queries intercepted after logging out should not result in a "jwt malformed" error. Instead, they should be handled gracefully as per the intercept logic.
Actual Behavior
After logging out, all queries intercepted result in a "jwt malformed" error.
Environment
Cypress Version: 13.5.1
Operating System: Windows 10
Additional relevant environment details: Graphql server on nest js
Workarounds
As a workaround, manually testing the functionality confirms that it works as expected. However, this is not a sustainable solution for automated testing scenarios.
Beta Was this translation helpful? Give feedback.
All reactions