Crate double_derive

Crate double_derive 

Source

Attribute Macros§

double
Generates a trait which replicates the original trait method for method. It does implement the original trait for each of its implementations, by means of forwarding the method calls. The utility comes from the fact that the generated trait has default implementations for each method using unimplemented!(), which makes it useful for testing purposes.
dummies
Generates a “dummy” implementation for each method in a trait using unimplemented!(). The main use case is to greate specialized test doubles for implementing the trait without worrying the need to explicitly implement methods, which are not invoked by the test.