       System.at_exit fn
         0 ->
           time = ExUnit.Server.cases_loaded()
-          config = put_defaults(configuration())
+          config = persist_defaults(configuration())
           %{failures: failures} = ExUnit.Runner.run(config, time)
           System.at_exit fn _ ->
             if failures > 0, do: exit({:shutdown, 1})

  of failures and the number of skipped tests.
  """
  def run do
    config = put_defaults(configuration())
    ExUnit.Runner.run(config, nil)
  end

  defp put_defaults(opts) do
    opts
    |> put_seed()
    |> put_max_cases()
  end

  defp put_seed(opts) do
    Keyword.put_new_lazy(opts, :seed, fn ->
      seed = :os.timestamp |> elem(2)
      Application.put_env(:ex_unit, :seed, seed)
      seed
    end)
  end

  defp put_max_cases(opts) do
    max_cases = max_cases(opts)
    Application.put_env(:ex_unit, :max_cases, max_cases)
    Keyword.put(opts, :max_cases, max_cases)
  end

  defp max_cases(opts) do

  """
  def configuration do
    Application.get_all_env(:ex_unit)
    |> put_seed()
    |> put_max_cases()
  end

  @doc """
