Powered by AppSignal & Oban Pro
Would you like to see your link here? Contact us

Unit Testing

livebooks/elixir/unit_testing.livemd

Unit Testing

Example

defmodule Hello do
  def world do
    "hello world"
  end
end
ExUnit.start(autorun: false)

defmodule HelloTest do
  use ExUnit.Case, async: true

  test "it works" do
    assert Hello.world() == "hello world"
  end
end

ExUnit.run()