View Source Repatch (Repatch v0.0.1)
Final word in Elixir testing
Summary
Types
@type allow_option() :: {:force, boolean()}
@type called_check_option() :: {:by, pid() | :any} | {:at_least, :once | pos_integer()} | {:exactly, :once | pos_integer()} | {:after, monotonic_time_native :: integer()} | {:before, monotonic_time_native :: integer()}
@type fake_option() :: recompile_option() | {:mode, mode()}
@type mode() :: :local | :shared | :global
@type patch_option() :: recompile_option() | {:mode, :local | :shared | :global} | {:force, boolean()}
@type recompile_option() :: {:ignore_forbidden_module, boolean()}
@type repatched_check_option() :: {:mode, mode() | :any}
@type restore_option() :: {:mode, mode()}
@type spy_option() :: recompile_option() | {:by, pid()}
@type tag() :: :patched | mode()
Functions
@spec allow(pid(), pid(), [allow_option()]) :: :ok
@spec cleanup(pid()) :: :ok
@spec fake(module(), module(), [fake_option()]) :: :ok
@spec patch(module(), atom(), [patch_option()], function()) :: :ok
@spec repatched?(module(), atom(), arity(), [repatched_check_option()]) :: boolean()
@spec restore(module(), atom(), arity(), [restore_option()]) :: :ok
@spec restore_all() :: :ok
@spec setup([setup_option()]) :: :ok
@spec spy(module(), [spy_option()]) :: :ok