Last active
April 28, 2025 04:57
-
-
Save FrankApiyo/25a3f980fef210450d2e88291294ca84 to your computer and use it in GitHub Desktop.
Sample LV test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defmodule AppNameWeb.LvLiveTest do | |
use UrlshortenerWeb.ConnCase, async: true | |
import Phoenix.LiveViewTest | |
describe "LV test" do | |
test "we can render the view", %{conn: conn} do | |
{:ok, _lv, html} = live(conn, ~p"/") | |
# open_browser(lv) | |
# html= lv |> element("form") |> render_submit(%{}) | |
assert html =~ "Original URL" | |
assert html =~ "Shorten!" | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment