mirror of
https://github.com/Fission-AI/OpenSpec.git
synced 2026-09-14 20:16:53 +08:00
5a4837c37d
* feat: add CLI e2e testing improvement plan ## Summary - Add phased approach to stabilize CLI spawn testing - Expand cross-shell/OS matrix coverage when stable - Optional packaging validation for CI environments * feat: add markdown parser CRLF fix proposal and update e2e plan - Add comprehensive proposal for fixing CRLF parsing issues on Windows - Update CLI path references from dist/cli.js to dist/cli/index.js - Streamline e2e testing tasks based on refined approach * fix: correct spec delta to add parsing requirement instead of modifying remediation - Change from MODIFIED to ADDED Requirements for cross-platform line ending parsing - Create focused requirement for parser behavior rather than validation messages - Maintain logical coherence between requirement and scenario
1.4 KiB
1.4 KiB
Why
Recent cross-shell regressions for openspec commands revealed that our existing unit/integration tests do not exercise the packaged CLI or shell-specific behavior. The prior attempt at Vitest spawn tests stalled because it coupled e2e coverage with pnpm pack installs, which fail in network-restricted environments. With those findings incorporated, we now need an approved plan to realign the work.
What Changes
- Adopt a phased strategy that first stabilizes direct spawn testing of the built CLI (
node dist/cli/index.js) using lightweight fixtures and shared helpers. - Expand coverage to cross-shell/OS matrices once the spawn harness is stable, ensuring both the direct
node dist/cli/index.jsinvocation and the bin shim are exercised with non-TTY defaults and captured diagnostics. - Treat packaging/install validation as an optional CI safeguard: when a runner has registry access, run a simple pnpm-based pack→install→smoke-test flow; otherwise document it as out of scope while closing remaining hardening items.
Impact
- Tests: add
test/cli-e2espawn suite, helpers, and fixture usage updates; adjustvitest.setup.tsas needed. - Tooling: update GitHub Actions workflows to add shell/OS matrices and (optionally) a packaging install check where network is available.
- Docs: keep
CROSS-SHELL-PLAN.mdaligned with the phased rollout and record any limitations called out during execution.