Clear screen on every run
This commit is contained in:
@@ -3,7 +3,7 @@ defmodule Display do
|
||||
@current_dir File.cwd!
|
||||
|
||||
def show_failure(%{expr: expr}, module, name) do
|
||||
IO.puts("")
|
||||
clear_screen
|
||||
IO.puts("Now meditate upon #{display_module(module)}")
|
||||
IO.puts("---------------------------------------")
|
||||
IO.puts(format_cyan(display_failed_assertion(module, expr)))
|
||||
@@ -15,9 +15,9 @@ defmodule Display do
|
||||
IO.puts("Considering #{display_module(module)}...")
|
||||
end
|
||||
|
||||
def before_run do
|
||||
IO.puts("")
|
||||
IO.puts("")
|
||||
def clear_screen do
|
||||
IO.puts(ANSI.clear)
|
||||
IO.puts(ANSI.home)
|
||||
end
|
||||
|
||||
def display_failed_assertion(module, expr) do
|
||||
|
||||
@@ -13,8 +13,6 @@ defmodule Runner do
|
||||
end
|
||||
|
||||
def run(start_module) do
|
||||
Display.before_run
|
||||
|
||||
start_idx = Enum.find_index(@modules, &(&1 == start_module))
|
||||
Enum.drop(@modules, start_idx)
|
||||
|> Enum.take_while(fn(mod) ->
|
||||
|
||||
Reference in New Issue
Block a user