Satisfying a standard interface like io.Reader or io.Writer correctly is not just a matter matching the function signatures, but rather adhering to behaviour that is documented in comments <https://golang.org/pkg/io/#Reader>
Is there a standard way for me to specify an implementation of such an interface and run an existing suite of tests against it that verify the behaviour is indeed as expected? So, in other words, does something like testing.TestBehaviour(myReader,io.Reader) or testing.SatisfiesIoReader(myReader) exist? To clarify, I'm not asking how to write tests that verify the implementation of a standard interface. Rather, I want to know if there is a way I can reuse tests that already exist for an implementation that I wrote? -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.