Plushie.Test.Case (Plushie v0.6.0)

Copy Markdown View Source

ExUnit case template for testing Plushie apps.

Starts a real Plushie app (Runtime + Bridge) connected to the shared renderer session pool before each test, and stops it on exit.

Usage

defmodule MyApp.CounterTest do
  use Plushie.Test.Case, app: MyApp.Counter

  test "clicking increment updates counter" do
    click("#increment")
    assert find!("#count") |> text() == "1"
  end
end