`ObserverSpy` swallows errors
shairez opened this issue ยท 1 comments
shairez commented
Describe the bug
When an error is thrown unexpectedly, the error
method on the ObserverSpy
catches it and basically "hides" it from the user.
And by that making debugging an unexpected error much more difficult.
To Reproduce
Steps to reproduce the behavior:
- throw an error in an observable
- See no trace of it in the logs
Expected behavior
We should be able to configure the observer spy (on creation or via subscribeSpyTo
) to flag whether an error is expected or not.
The default should be that the error is not expected and should be re-thrown so it would be shown in the console.
shairez commented
๐ This issue has been resolved in version 2.0.0 ๐
The release is available on:
Your semantic-release bot ๐ฆ๐