- Add acceptance criteria documentation (AC-0013 through AC-0023) - Add Line-0003 discovery documentation - Implement Strategy Catalog v1 with new database migration - Update portfolio API endpoints and schemas - Refactor strategy and portfolio services - Add strategy management CLI commands - Update domain models with strategy catalog support - Add comprehensive tests for v1 strategies - Update design documentation (data model, interfaces, runtime flows)
1.2 KiB
1.2 KiB
id, status
| id | status |
|---|---|
| ac-0017 | active |
포트폴리오 ID-only 요청과 응답 호환성 계약
Criterion
/v1/portfolios와 legacy /portfolios의 생성에는 active strategy_id가 필수이고 수정도 ID-only여야 하며, 요청의 strategy_name·strategy_params는 422로 거부하는 동시에 응답의 active_strategy_id·strategy_name·strategy_params·strategy_revision은 유지되어야 한다.
Verification
- 성공 조건: 명시한 active ID로만 포트폴리오가 생성·수정되고 응답에 현재 전략 identity·이름·config·revision이 나타난다.
- 실패·경계 조건: strategy ID 누락, 제거 필드 전달 또는 malformed 요청은 새 전략 row를 만들지 않고
422다. - 검사 방법: v1·legacy create/update schema와 저장소 row count, 응답 호환 필드를 API/CLI 회귀로 검사한다.
- 현재 구현 평가: schemas와 양쪽 portfolio API가 ID-only 입력 및
extra="forbid"계약을 구현하고 scoped portfolio/CLI 회귀는 PASS했다. 다만 제거된strategy_name·strategy_params각각의422와 응답 호환 필드 전체를 직접 단언하는 전용 negative/response test는 현재 없어 해당 executable coverage는PARTIAL이다.