"""OP-01 — `mtest --version` returns a RICH version (not just the bare number)."""

from __future__ import annotations

import subprocess
import sys


def test_version_is_rich() -> None:
    out = subprocess.run(
        [sys.executable, "-m", "mgf.test_supervisor", "--version"],
        capture_output=True,
        text=True,
        check=True,
    )
    text = out.stdout + out.stderr
    assert "mgf-test-supervisor" in text
    assert "python:" in text and "platform:" in text and "commit:" in text
