-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Debugging Jest unit tests with mobx proxies and displayed values #2873
Comments
Thanks for sharing the repo. The issue is now fixed and the fix is published in the latest Wallaby Core v1.0.1189. |
Thank you for the quick fix. However there is still a problem with objects. I have updated the repo. |
Thanks for checking. The issues are now fixed and the fix is published in the latest Wallaby Core v1.0.1190. Please note that mobx proxy symbol will still be visible (by design) in Value Explorer (it reveals hidden properties unlike plain console.log). It is because the object is still a "proxy" (in both Wallaby and Jest CLI), but the symbol data on the object should not interfere with assertion diffs or inline logs. |
Thank you. |
Sounds interesting, I have created the feature request at #2875. For now you may use a simple live comment (may even create a WS live template to quickly insert it) to get the compact view: const instance = new FooClass();
instance.addObj({name:"bar"});
instance //? require('mobx').toJS($) |
Issue description or question
I have trouble using Wallaby with a Mobx project. Mobx is a state management library that allow you to observe some data change wrapping the data with a proxy.
When the tests are red, instead of seeing the actual (wrong) output under Wallaby, i see the proxy.
Running the same test with the same configuration under Jest without Wallaby gives me the actual output and not the proxy.
Also, using the wallaby debugger and peeking at values, i see the proxy and not the values.
Repro demonstrating the issue :
/~https://github.com/vjau/bugmobxwallaby
Wallaby diagnostics report
The text was updated successfully, but these errors were encountered: