ESpec.AssertionHelpers

Defines helper functions for modules which use ESpec. These functions wrap arguments for ESpec.ExpectTo module. See ESpec.Assertion module for corresponding ‘assertion modules’

Source

Summary

accepted(func, args \\ :any, opts \\ [pid: :any, count: :any])
be(value)
be(operator, value)
be_atom()
be_between(min, max)
be_binary()
be_bitstring()
be_boolean()
be_close_to(value, delta)
be_empty()
be_false()
be_falsy()
be_float()
be_function()
be_function(arity)
be_integer()
be_list()
be_map()
be_nil()
be_number()
be_pid()
be_port()
be_printable()
be_reference()
be_struct()
be_struct(name)
be_true()
be_truthy()
be_tuple()
be_valid_string()
change(func, value)
change(func, before, value)
end_with(value)
eq(value)
eq_dict(value)
eql(value)
have(val)
have_all(func)
have_any(func)
have_at(pos, val)
have_count(value)
have_count_by(func, val)
have_first(value)
have_hd(value)
have_key(value)
have_last(value)
have_length(value)
have_max(value)
have_max_by(func, value)
have_min(value)
have_min_by(func, value)
have_size(value)
have_tl(value)
have_value(value)
match(value)
raise_exception()
raise_exception(exception)
raise_exception(exception, message)
start_with(value)
throw_term()
throw_term(term)

Functions

accepted(func, args \\ :any, opts \\ [pid: :any, count: :any])
Source
be(value)
Source
be(operator, value)
Source
be_atom()
Source
be_between(min, max)
Source
be_binary()
Source
be_bitstring()
Source
be_boolean()
Source
be_close_to(value, delta)
Source
be_empty()
Source
be_false()
Source
be_falsy()
Source
be_float()
Source
be_function()
Source
be_function(arity)
Source
be_integer()
Source
be_list()
Source
be_map()
Source
be_nil()
Source
be_number()
Source
be_pid()
Source
be_port()
Source
be_printable()
Source
be_reference()
Source
be_struct()
Source
be_struct(name)
Source
be_true()
Source
be_truthy()
Source
be_tuple()
Source
be_valid_string()
Source
change(func, value)
Source
change(func, before, value)
Source
end_with(value)
Source
eq(value)
Source
eq_dict(value)
Source
eql(value)
Source
have(val)
Source
have_all(func)
Source
have_any(func)
Source
have_at(pos, val)
Source
have_count(value)
Source
have_count_by(func, val)
Source
have_first(value)
Source
have_hd(value)
Source
have_key(value)
Source
have_last(value)
Source
have_length(value)
Source
have_max(value)
Source
have_max_by(func, value)
Source
have_min(value)
Source
have_min_by(func, value)
Source
have_size(value)
Source
have_tl(value)
Source
have_value(value)
Source
match(value)
Source
raise_exception()
Source
raise_exception(exception)
Source
raise_exception(exception, message)
Source
start_with(value)
Source
throw_term()
Source
throw_term(term)
Source