d0f265ef62
CI / lint (push) Waiting to run
CI / typecheck (push) Waiting to run
CI / security (push) Waiting to run
CI / quality (push) Waiting to run
CI / unit_tests (push) Waiting to run
CI / integration_tests (push) Waiting to run
CI / coverage (push) Blocked by required conditions
CI / build (push) Waiting to run
CI / docker (push) Blocked by required conditions
CI / lint (pull_request) Successful in 15s
CI / typecheck (pull_request) Successful in 29s
CI / security (pull_request) Successful in 23s
CI / quality (pull_request) Successful in 15s
CI / integration_tests (pull_request) Successful in 5m3s
CI / build (pull_request) Successful in 15s
CI / unit_tests (pull_request) Successful in 16m30s
CI / coverage (pull_request) Successful in 8m20s
CI / docker (pull_request) Successful in 41s
43 lines
1.9 KiB
Gherkin
43 lines
1.9 KiB
Gherkin
Feature: Plan lifecycle persistence via repositories
|
|
The PlanLifecycleService persists actions and plans via
|
|
ActionRepository and LifecyclePlanRepository (via UnitOfWork)
|
|
instead of relying solely on in-memory maps.
|
|
|
|
Background:
|
|
Given a persisted plan lifecycle service backed by SQLite
|
|
|
|
Scenario: Create action via service persists to DB
|
|
When I create a persisted action "local/persist-act" with definition "All tests pass"
|
|
Then the action "local/persist-act" should be retrievable from a fresh DB session
|
|
|
|
Scenario: Create plan via use_action persists to DB
|
|
Given a persisted action "local/plan-persist" exists
|
|
When I use the persisted action "local/plan-persist" to create a plan
|
|
Then the plan should be retrievable from a fresh DB session
|
|
|
|
Scenario: Phase transition strategize to execute persists
|
|
Given a persisted plan in strategize-complete state
|
|
When I execute the persisted plan
|
|
Then the persisted plan phase should be "execute"
|
|
And the persisted plan processing state should be "queued"
|
|
|
|
Scenario: Phase transition execute to apply persists
|
|
Given a persisted plan in execute-complete state
|
|
When I apply the persisted plan
|
|
Then the persisted plan phase should be "apply"
|
|
And the persisted plan processing state should be "queued"
|
|
|
|
Scenario: List plans from DB matches in-memory
|
|
Given a persisted action "local/list-act" exists
|
|
When I use the persisted action "local/list-act" to create a plan
|
|
Then listing plans should return 1 plan
|
|
|
|
Scenario: Duplicate action name rejected by persistence layer
|
|
Given a persisted action "local/dup-action" exists
|
|
When I try to create another persisted action "local/dup-action"
|
|
Then the duplicate action creation should fail with an error
|
|
|
|
Scenario: Missing action error surfaced clearly
|
|
When I try to use a non-existent persisted action "local/no-such-action"
|
|
Then the missing action error should mention "local/no-such-action"
|