[erlang-questions] Unit Testing gen_server callbacks
Tue Aug 14 08:41:38 CEST 2012
It should be easy enough to unit test such things, just run a handle_call
with the right arguments, and verify that the output and new state is
I don't think there's a need to actually start the gen_server itself and
unit test the callbacks by going through gen_server:call, if that's what
you mean. In what way do you find it to be fragile?
On 14 August 2012 03:48, Jan Vincent Liwanag <> wrote:
> What are your thoughts on unit testing gen_server (or other gen_*)
> callbacks (handle_call, etc) directly? Is this an ok practice? Or should
> unit tests test only the public api?
> On my end, I find testing gen_server callbacks to be rather fragile. Eager
> to hear out other thoughts.
> Jan Vincent Liwanag
> +63 (999) 888-0247
> erlang-questions mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the erlang-questions