I'm discovering a lib availaible on github. I'm interested by functions defined in its unit-tests because I don't find any example elsewhere how to use the lib. I understand it is not primary goal of these functions to be usable by end-user. But, I would like to know if there is a way to use them cleanly if possible rather than copy-paste snippets. If it is only a bad practice, how do you proceed in a similar case?
The function is not exposed to users but it is public. It seems contradictory at first view. I guess it stems from a bad practice to put "pub" everywhere. Can it be legitimate to define a pub function after #[test] annotation?