ExUnit.Formatter.ANSI
Elixir
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib
test
.gitignore
README.md
mix.exs
mix.lock
package.exs

README.md

ExUnit.Formatter.ANSI

An ANSI color sequence enabling formatter for ExUnit. If its printing to a TTY, it will print using ANSI sequences, otherwise it will revert to colorless printing.

Usage

Just add

ExUnit.configure formatter: ExUnit.Formatter.ANSI

after ExUnit.start in your test/test_helper.exs file

You can also use this formatter globally. To enable this, create a file called $HOME/.ex_unit.exs with this content:

[formatter: ExUnit.Formatter.ANSI]

and update your user-wide ERL_LIBS to point to directories that include ex_unit_ansi and ex_unit_ansi's deps.