Elixir mock (test double) testing seams: a modest proposal

When using mocks in Elixir, particularly with Mox then the standard way of loading the implementation is along the lines of Application.get_env(:cat_facts, CatFacts.CatFactsApi, CatFacts.RealCatFactsApi) . In this post I suggest an alternative which is a little less flexible, but also safer and avoid extra configuration.

1 Like

Corresponding tweet for this thread:

Share link for this tweet.

1 Like