Skip to content

test: add schema-gated full lifecycle integration test#49

Merged
jpicklyk merged 4 commits intomainfrom
test/schema-gated-lifecycle-integration
Mar 6, 2026
Merged

test: add schema-gated full lifecycle integration test#49
jpicklyk merged 4 commits intomainfrom
test/schema-gated-lifecycle-integration

Conversation

@jpicklyk
Copy link
Owner

@jpicklyk jpicklyk commented Mar 6, 2026

Summary

  • Adds SchemaGatedLifecycleTest (338 lines, 5 test cases) validating the complete schema-gated workflow lifecycle
  • Tests gate enforcement at every phase transition (queue→work→review→terminal) for both feature-implementation and bug-fix schemas
  • Verifies schema-free mode (no tags = no gates), empty note body rejection, and complete trigger requiring all phase notes
  • Uses H2 in-memory database with real repositories (not mocks) and inline NoteSchemaService

Test Results

  • SchemaGatedLifecycleTest: 5/5 pass
  • Full suite: BUILD SUCCESSFUL, no regressions

Review

Independent review passed — all acceptance criteria met, tests are substantive (none pass with gates removed), code follows existing WorkflowIntegrationTest patterns.

MCP Items

  • e926961c — Schema-gated full lifecycle integration test

🤖 Generated with Claude Code

jpicklyk and others added 4 commits March 5, 2026 19:12
Validates complete schema-gated progression (queue→work→review→terminal)
with gate enforcement at each transition. Tests both feature-implementation
and bug-fix schemas, schema-free mode, empty note body rejection, and
the complete trigger requiring all phase notes.

5 test cases using H2 in-memory database + real repositories (not mocks)
with inline NoteSchemaService mirroring production config.yaml schemas.

MCP item: e926961c-e029-493d-b820-4054e34efc9a

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…nsistency checks

Adds 6 new test cases (11 total) targeting complex scenarios that could
expose response/DB inconsistencies:

- Child start cascading parent to work (with response verification)
- Parent with schema tag — cascade bypasses start-trigger gate
- Batch transitions with mixed gate outcomes (pass/fail/schema-free)
- Full lifecycle with parent cascade and response/DB consistency at every step
- Rapid sequential note fills and advances
- Multiple children with different schemas under shared parent

Introduces assertResponseMatchesDb() helper that verifies advance_item
response matches actual DB state after each transition.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Adds mixed-schema tag with required + optional notes per phase,
including a review phase with only optional notes. 4 new test cases:

- Gate only blocks on required notes, ignores optional
- Review phase with only optional notes advances freely
- Complete trigger only checks required notes across all phases
- Filling optional note does not satisfy required note gate

15 total tests in SchemaGatedLifecycleTest.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@jpicklyk jpicklyk merged commit e6ee08b into main Mar 6, 2026
2 checks passed
@jpicklyk jpicklyk deleted the test/schema-gated-lifecycle-integration branch March 6, 2026 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant