Run only one test in Elixir

Add a tag for e.g. @tag runnable: true at the top of the test you want to run, like bellow:

  @tag runnable: true # <-- this bit
  test "run only this test" do
    assert true
  end

Then run the mix test task with the --only option like:

  mix test --only runnable:true

Note: there is no space between the tag name: runnable with a colon and the value: true resulting in runnable:true

If you want other options theres a great post on medium: Elixir testing: running only specific tests