core/tools+test: make process and path checks Windows-portable

Use sys.executable for process tests; normalize denylist/glob paths; skip readline when missing.
This commit is contained in:
2026-07-15 20:20:25 +08:00
parent e1547a242c
commit fbba2c2a14
6 changed files with 58 additions and 27 deletions
+8
View File
@@ -1,5 +1,8 @@
from __future__ import annotations
import importlib.util
import pytest
import tomlkit
from plyngent.cli.readline_setup import (
@@ -12,6 +15,11 @@ from plyngent.cli.state import ReplState
from plyngent.config.models import ModelConfig, OpenAICompatibleProvider, OpenAIProvider
from plyngent.config.store import ConfigStore
pytestmark = pytest.mark.skipif(
importlib.util.find_spec("readline") is None,
reason="readline not available (e.g. Windows/Wine)",
)
def _minimal_state(tmp_path: object) -> ReplState:
from pathlib import Path