pagantis_elixir_tools v0.10.1 ElixirTools.ContractImpl

This support module helps with implementing contracts in tests. It ensures that the signature of a method is right. This is done by creating dynamically a contract for all public functions.

To use this helper, add to the contract of the module that you want to implement: use ElixirTools.ContractImpl, module: MyApp.TestModule

Then, all mocked methods must be using @impl true.

There is a caveat. At this moment, the specs themselves are not tested, as test files are exs files thus not dialyzable.

Link to this section Summary

Link to this section Functions

Link to this function

arg_to_module(_)
arg_to_module(any()) :: module() | no_return()

Link to this function

arg_to_module!(arg)