What is Nostr?
Greg /
npub122k…dp80
2024-03-27 14:49:30

Greg on Nostr: I've been struggling for the past few days with setting up mock dependencies in unit ...

I've been struggling for the past few days with setting up mock dependencies in unit tests for a #rust project. This is first time I'm using mocks in Rust, and it feels like pushing a boulder up a hill. The idea is to swap out types of dependencies with your own implementations, so that you can measure how your own code-under-test behaves while interacting with a dependency. The borrow-checker cop, and design choices that authors of a library can make, conspire against me.
Author Public Key
npub122khkty8jumvtwtx4fd3whfdz3tr4d4pvurc5lyaxh6zzzpl3ezqd6dp80