-
Notifications
You must be signed in to change notification settings - Fork 16
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
Mock struct in external crate does not work #26
Comments
I took the liberty of editing the formatting of your post a bit, I hope you do not mind it was just a bit hard to read. Unfortunately, this is the expected behavior due to the way For more info: https://stackoverflow.com/questions/41700543/can-we-share-test-utilites-between-crates. Eventually I want to provide workarounds for this limitation, or at least specified suggestions within a small guide of how to make it work but it couldn't be through the |
Thank you @nrxus for the answer. Please keep the good work going, I search all github trying to find something could mock my db/network calls easily. Feel there is a lot potential in faux! A guide on how to work around this for now will be super helpful!! |
I also feel like there is a lot of potential here, thanks for looking at I created a new issue specifically about exploring and documenting a way to export mocks through crates so I am going to close this one. |
Doesn't work because src/ not compiled with cfg(test) switch by design in rust when building integration tests in tests/ nrxus/faux#26
The text was updated successfully, but these errors were encountered: