I wonder if someone had simmilar adventures in testing Sveltes app in Cypress or is it just my poor code that causes the problems.
The repo:
https://github.com/pietranikm/svelteApp
I try to create tests for Svelte app that I've wrote, but I got stuck on a page being redirected when I submit the form. In the app I use Svelte's trick to prevent redirection - adding on:submit|preventDefault and in a regular browser everything works fine.
But when I run the tests in Cypress, after triggering some action on the page I'm being redirected to the page with response data from the api call. It happens often but not all the time on adding the todos tests, but always on removing todos.
I have not found much in a topic of E2E testing for Svelte apps, but I have a suspicion that this migth be a common problem. Do you have any idea on how I could prevent the app to redirect, preferably inside the Cypress tests?