Replies: 1 comment
-
I suppose you can do the opposite, mock out computed and effects so that they don't track signal changes? Would generally advise against mocks though -- testing anything other than the code you're actually running in production is of questionable value. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Is there a library or technique which can be used to mock signals?
When we string together an entire state flow using signals and effects, we make the testing of any method that relies on a signal's value extremely difficult because downstram notifications are going to fire.
It would be convenient if there was a method to set the signal's value without triggering notifications for these types of cases.
How do you test code with a heavy use of signals today?
Beta Was this translation helpful? Give feedback.
All reactions