defmodule HeroiconsTest do use ExUnit.Case, async: true import Phoenix.LiveViewTest test "generated function" do assert Heroicons.Outline.academic_cap() |> Phoenix.HTML.safe_to_string() =~ ~s( Phoenix.HTML.safe_to_string() =~ ~s(class="h-6 w-6 text-gray-500") assert Heroicons.Outline.academic_cap(class: "<> \" ") |> Phoenix.HTML.safe_to_string() =~ ~s(class="<> " ") assert Heroicons.Outline.academic_cap(foo: "bar") |> Phoenix.HTML.safe_to_string() =~ ~s(foo="bar") assert Heroicons.Outline.academic_cap(multiword_key: "foo") |> Phoenix.HTML.safe_to_string() =~ ~s(multiword-key="foo") assert Heroicons.Outline.academic_cap(viewBox: "0 0 12 12") |> Phoenix.HTML.safe_to_string() =~ ~s(viewBox="0 0 12 12") end test "generated components" do assert render_component(&Heroicons.Outline.academic_cap/1, assigns()) =~ ~s(