discourse (forum: postgres+redis+sidekiq). HEALTH_PATH=/srv/status (slow Rails boot, DEPLOY_TIMEOUT=1800). P4 via postgres ci_marker (db service, pg_dump backupbot — matrix-synapse pattern). Health functional test. §4.3 create-a-topic + PARITY.md to follow after smoke discovers the admin/API bootstrap path. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
21 lines
845 B
Python
21 lines
845 B
Python
"""discourse — health/readiness functional test (Phase 2).
|
|
|
|
SOURCE: no recipe-maintainer corpus exists for discourse (P2 vacuous — see PARITY.md). This is a
|
|
Phase-2 health check aligned with the parity-port convention: /srv/status returns 200 only once the
|
|
Rails app is actually serving (the recipe's HEALTH_PATH and the canonical "is discourse up" signal).
|
|
"""
|
|
|
|
from __future__ import annotations
|
|
|
|
import os
|
|
import sys
|
|
|
|
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "..", "..", "..", "runner"))
|
|
from harness import http as harness_http # noqa: E402
|
|
|
|
|
|
def test_discourse_srv_status_ok(live_app):
|
|
url = f"https://{live_app}/srv/status"
|
|
status, _ = harness_http.retry_http_get(url, expect_status=200, max_wait=120, interval=5)
|
|
assert status == 200, f"GET {url} HTTP {status} (expected 200 — discourse not serving)"
|