it looks like SuperTokens.init() makes an HTTP request. Is there any easy way to mock SuperTokens so that this doesn't happen during my tests?
r
rp_st
08/11/2022, 3:29 AM
Hey! There isn’t a way to stop that at the moment I’m afraid. Maybe open an issue about this. For now, you can surround it with a try catch and ignore the error. Things should still work fine regardless.
a
Al V
08/11/2022, 12:51 PM
We ended up mocking the module using jest mocks and mocking init so that the real init doesn't get called during tests
SuperTokens is an open source authentication solution offering features like: Different types of login: Email / password, Passwordless (OTP or Magic link based).