from pathlib import Path def test_progress_bar_has_motion_feedback_css(): css = Path("web/static/app.css").read_text(encoding="utf-8") for token in [ "v56 feedback motion", "transition:width .75s cubic-bezier", "progress-shimmer", "progress-bump", "value-bump", "prefers-reduced-motion", ]: assert token in css def test_timeline_status_changes_are_detected_and_animated(): js = Path("web/static/progress.js").read_text(encoding="utf-8") for token in [ "timelineRenderState", "status-changed", "status-flash", "dot-pop", "animateClass", "timelineStepKey", ]: assert token in js def test_running_steps_pulse_and_status_badge_animates(): css = Path("web/static/app.css").read_text(encoding="utf-8") js = Path("web/static/progress.js").read_text(encoding="utf-8") assert "step-running-pulse" in css assert "status-bump" in css assert "animateStatusBadge" in js assert "lastStatus" in js def test_progress_render_uses_animated_progress_bar(): js = Path("web/static/progress.js").read_text(encoding="utf-8") assert "animateProgressBar(progress" in js assert "fill.classList.toggle('is-running'" in js assert "progressMotionState.lastProgress" in js