Bundle firecracker runtime and switch ollama demo to live logs
This commit is contained in:
parent
ef0ddeaa11
commit
65f7c0d262
26 changed files with 1896 additions and 408 deletions
27
tests/test_doctor.py
Normal file
27
tests/test_doctor.py
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import argparse
|
||||
import json
|
||||
|
||||
import pytest
|
||||
|
||||
import pyro_mcp.doctor as doctor_module
|
||||
|
||||
|
||||
def test_doctor_main_prints_json(
|
||||
monkeypatch: pytest.MonkeyPatch,
|
||||
capsys: pytest.CaptureFixture[str],
|
||||
) -> None:
|
||||
class StubParser:
|
||||
def parse_args(self) -> argparse.Namespace:
|
||||
return argparse.Namespace(platform="linux-x86_64")
|
||||
|
||||
monkeypatch.setattr(doctor_module, "_build_parser", lambda: StubParser())
|
||||
monkeypatch.setattr(
|
||||
doctor_module,
|
||||
"doctor_report",
|
||||
lambda platform: {"platform": platform, "runtime_ok": True, "issues": []},
|
||||
)
|
||||
doctor_module.main()
|
||||
output = json.loads(capsys.readouterr().out)
|
||||
assert output["runtime_ok"] is True
|
||||
Loading…
Add table
Add a link
Reference in a new issue