ca01e94d47
Add smoke tests for bulk cron workers, CSP browser header, and on_mount hooks (GetTimezone/StaticAssets). 9 tests across 4 files, all passing alongside 135 existing related tests.
15 lines
401 B
Elixir
15 lines
401 B
Elixir
defmodule MusicLibraryWeb.Hooks.StaticAssetsTest do
|
|
use MusicLibraryWeb.ConnCase
|
|
|
|
import Phoenix.LiveViewTest, only: [live: 2]
|
|
|
|
describe "on_mount/4" do
|
|
test "assigns :static_changed to a boolean", %{conn: conn} do
|
|
{:ok, view, _html} = live(conn, ~p"/collection")
|
|
socket = :sys.get_state(view.pid).socket
|
|
|
|
assert is_boolean(socket.assigns.static_changed)
|
|
end
|
|
end
|
|
end
|