feat(acms): context assembly CLI functional (context list/add/show/clear) #1138

Merged
aditya merged 2 commits from feature/m5-context-cli into master 2026-03-25 12:39:49 +00:00
Member

Summary

Verified and tested the context assembly CLI commands (context list, context add, context show, context clear) for full functionality with the ACMS context pipeline. Added missing unit test coverage for the required patterns.

Changes

Verified CLI Commands

  • agents context list — lists all context resources for the current plan/project via ContextService
  • agents context add — attaches file/directory resources to the current plan's context
  • agents context show — displays assembled context content (single file detail or multi-file summary)
  • agents context clear — clears all context state, enabling inheritance fallback to parent views

New Behave Test Scenarios (5 added to features/m5_acms_smoke.feature)

  • M5 smoke context list with multiple resources — verifies list with 3 entries
  • M5 smoke context add multiple files to project — verifies multi-file add
  • M5 smoke context show with multiple resources shows summary — verifies summary display
  • M5 smoke context clear then re-add restores entries — verifies clear + re-add pattern
  • M5 smoke context clear on empty project succeeds — verifies clear on empty context

E2E Acceptance Tests Passing

  • ACMS Scoped Context Output Per Phase — phase-specific views with narrowing size limits + persistence round-trip
  • Context Policy Clear And Inheritance Fallback — view clearing with inheritance fallback + persistence round-trip

Test Results

  • Unit tests: 12,235 scenarios passed (31 in m5_acms_smoke.feature)
  • Integration tests: 1,672 tests passed
  • Coverage: 98.38% (threshold: >97%)
  • Lint: Clean
  • Typecheck: 0 errors

Files Changed

  • features/m5_acms_smoke.feature — added 5 new scenarios (multiple resources, clear+re-add)
  • features/steps/m5_acms_smoke_steps.py — added corresponding step definitions

Closes #848

## Summary Verified and tested the context assembly CLI commands (`context list`, `context add`, `context show`, `context clear`) for full functionality with the ACMS context pipeline. Added missing unit test coverage for the required patterns. ## Changes ### Verified CLI Commands - **`agents context list`** — lists all context resources for the current plan/project via `ContextService` - **`agents context add`** — attaches file/directory resources to the current plan's context - **`agents context show`** — displays assembled context content (single file detail or multi-file summary) - **`agents context clear`** — clears all context state, enabling inheritance fallback to parent views ### New Behave Test Scenarios (5 added to `features/m5_acms_smoke.feature`) - `M5 smoke context list with multiple resources` — verifies list with 3 entries - `M5 smoke context add multiple files to project` — verifies multi-file add - `M5 smoke context show with multiple resources shows summary` — verifies summary display - `M5 smoke context clear then re-add restores entries` — verifies clear + re-add pattern - `M5 smoke context clear on empty project succeeds` — verifies clear on empty context ### E2E Acceptance Tests Passing - `ACMS Scoped Context Output Per Phase` — phase-specific views with narrowing size limits + persistence round-trip - `Context Policy Clear And Inheritance Fallback` — view clearing with inheritance fallback + persistence round-trip ## Test Results - **Unit tests**: 12,235 scenarios passed (31 in m5_acms_smoke.feature) - **Integration tests**: 1,672 tests passed - **Coverage**: 98.38% (threshold: >97%) - **Lint**: Clean - **Typecheck**: 0 errors ## Files Changed - `features/m5_acms_smoke.feature` — added 5 new scenarios (multiple resources, clear+re-add) - `features/steps/m5_acms_smoke_steps.py` — added corresponding step definitions Closes #848
aditya added this to the v3.4.0 milestone 2026-03-23 18:19:27 +00:00
freemo approved these changes 2026-03-24 15:27:08 +00:00
Dismissed
freemo left a comment

Review: APPROVED

Clean test-only PR adding 5 BDD scenarios for context CLI operations. Step implementations use proper mocking with the _mock_container() pattern consistent with existing steps. Multi-file add test patches Path.exists appropriately. Assertions are flexible to handle format variations. No concerns.

## Review: APPROVED Clean test-only PR adding 5 BDD scenarios for context CLI operations. Step implementations use proper mocking with the `_mock_container()` pattern consistent with existing steps. Multi-file add test patches `Path.exists` appropriately. Assertions are flexible to handle format variations. No concerns.
aditya force-pushed feature/m5-context-cli from adb4b55fee
All checks were successful
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 14s
CI / lint (pull_request) Successful in 3m19s
CI / typecheck (pull_request) Successful in 3m46s
CI / security (pull_request) Successful in 3m55s
CI / quality (pull_request) Successful in 4m5s
CI / integration_tests (pull_request) Successful in 6m44s
CI / unit_tests (pull_request) Successful in 7m15s
CI / docker (pull_request) Successful in 1m12s
CI / e2e_tests (pull_request) Successful in 8m40s
CI / coverage (pull_request) Successful in 9m56s
CI / status-check (pull_request) Successful in 0s
CI / benchmark-regression (pull_request) Successful in 58m17s
to 57bccbdbe4
Some checks failed
CI / benchmark-publish (pull_request) Has been skipped
CI / lint (pull_request) Successful in 3m21s
CI / build (pull_request) Failing after 20s
CI / quality (pull_request) Successful in 4m3s
CI / typecheck (pull_request) Successful in 4m9s
CI / security (pull_request) Successful in 4m20s
CI / unit_tests (pull_request) Successful in 7m16s
CI / integration_tests (pull_request) Successful in 6m48s
CI / docker (pull_request) Successful in 1m23s
CI / e2e_tests (pull_request) Failing after 6m13s
CI / coverage (pull_request) Successful in 11m47s
CI / status-check (pull_request) Successful in 2s
CI / benchmark-regression (pull_request) Has been cancelled
2026-03-25 06:10:45 +00:00
Compare
Author
Member

rebased with master, already approved, merging

rebased with master, already approved, merging
aditya scheduled this pull request to auto merge when all checks succeed 2026-03-25 06:15:59 +00:00
aditya dismissed freemo's review 2026-03-25 11:19:17 +00:00
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

aditya force-pushed feature/m5-context-cli from 54f4ca1b71
Some checks failed
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 17s
CI / unit_tests (pull_request) Has been cancelled
CI / typecheck (pull_request) Has been cancelled
CI / lint (pull_request) Has been cancelled
CI / e2e_tests (pull_request) Has been cancelled
CI / quality (pull_request) Has been cancelled
CI / security (pull_request) Has been cancelled
CI / integration_tests (pull_request) Has been cancelled
CI / docker (pull_request) Has been cancelled
CI / coverage (pull_request) Has been cancelled
CI / benchmark-regression (pull_request) Has been cancelled
CI / status-check (pull_request) Has been cancelled
to f258aacc5d
Some checks failed
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 15s
CI / integration_tests (pull_request) Successful in 3m42s
CI / quality (pull_request) Successful in 3m47s
CI / unit_tests (pull_request) Successful in 7m11s
CI / e2e_tests (pull_request) Successful in 9m57s
CI / lint (pull_request) Successful in 3m15s
CI / typecheck (pull_request) Successful in 4m15s
CI / benchmark-regression (pull_request) Has been cancelled
CI / coverage (pull_request) Has been cancelled
CI / docker (pull_request) Has been cancelled
CI / status-check (pull_request) Has been cancelled
CI / security (pull_request) Has been cancelled
2026-03-25 11:27:04 +00:00
Compare
aditya force-pushed feature/m5-context-cli from f258aacc5d
Some checks failed
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 15s
CI / integration_tests (pull_request) Successful in 3m42s
CI / quality (pull_request) Successful in 3m47s
CI / unit_tests (pull_request) Successful in 7m11s
CI / e2e_tests (pull_request) Successful in 9m57s
CI / lint (pull_request) Successful in 3m15s
CI / typecheck (pull_request) Successful in 4m15s
CI / benchmark-regression (pull_request) Has been cancelled
CI / coverage (pull_request) Has been cancelled
CI / docker (pull_request) Has been cancelled
CI / status-check (pull_request) Has been cancelled
CI / security (pull_request) Has been cancelled
to 2aa2bb6a43
Some checks failed
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 24s
CI / lint (pull_request) Successful in 3m30s
CI / typecheck (pull_request) Successful in 4m0s
CI / quality (pull_request) Successful in 3m37s
CI / security (pull_request) Successful in 4m22s
CI / integration_tests (pull_request) Successful in 7m14s
CI / e2e_tests (pull_request) Successful in 10m12s
CI / coverage (pull_request) Successful in 10m11s
CI / unit_tests (pull_request) Successful in 5m51s
CI / docker (pull_request) Successful in 1m7s
CI / status-check (pull_request) Successful in 1s
CI / benchmark-regression (pull_request) Has been cancelled
2026-03-25 12:05:42 +00:00
Compare
aditya scheduled this pull request to auto merge when all checks succeed 2026-03-25 12:28:27 +00:00
aditya merged commit 37c1329257 into master 2026-03-25 12:39:49 +00:00
aditya deleted branch feature/m5-context-cli 2026-03-25 12:39:50 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
cleveragents/cleveragents-core!1138
No description provided.