#!/usr/bin/env bash
set -euo pipefail
HERE=$(CDPATH= cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)
ROOT=$(CDPATH= cd -- "$HERE/../../.." && pwd)
FILE="$ROOT/docs/mockups/k3s-phase2-enrollment.html"
[[ -s "$FILE" ]]
grep -Fq '<!doctype html>' "$FILE"
grep -Fq 'One-command enrollment' "$FILE"
grep -Fq 'data-view="transaction"' "$FILE"
grep -Fq 'execution state' "$FILE"
grep -Fq 'Phase 2 · dry-run only' "$FILE"
grep -Fq 'addEventListener' "$FILE"
! grep -Eqi '<script[^>]+src=|<link[^>]+href=https?://' "$FILE"
echo 'phase2 enrollment presentation: passed'
