import os import sys # Ensure repo root is on sys.path when running as a script. ROOT = os.path.abspath(os.path.join(os.path.dirname(__file__), "..")) if ROOT not in sys.path: sys.path.insert(0, ROOT) from app import create_app def main(): app = create_app() rules = sorted({str(r) for r in app.url_map.iter_rules()}) print("App created:", app.name) print("Routes:") for r in rules: print(" -", r) required = { "/admin/companies//delete", "/admin/displays//name", "/company/displays/", "/company/items//duration", "/company/playlists//items/reorder", "/auth/change-password", "/auth/forgot-password", "/auth/reset-password/", } missing = sorted(required.difference(rules)) if missing: raise SystemExit(f"Missing expected routes: {missing}") if __name__ == "__main__": main()