Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am bangn on github.
  • I am bangn (https://keybase.io/bangn) on keybase.
  • I have a public key ASC-lAXoDG42F7z0uC-ijnyfwcsN-AVAQnPLh8rud3L5GQo

To claim this, I am signing this object:

@bangn
bangn / my_app_test.exs
Last active June 26, 2020 14:49
Set up Ecto to run test in Sanbox mode
defmodule MyApp.Test do
use ExUnit.Case, async: true
use Plug.Test
setup do
# Checkout repo manually.
# TODO: figure out how to do it automatically.
:ok = Ecto.Adapters.SQL.Sandbox.checkout(MyApp.Repo)
end