WorkOrderFixture.build for the 73 tests that hand-build WorkOrder #1464
Labels
No labels
P0
P1
P2
P3
bug
category/code-change
category/cross-repo
category/eval-run
category/investigation
category/no-test-target
category/owner-ruling
category/prose-artifact
category/recurring-chore
category/structure
category/umbrella
crc-refactor
create
delete
enhancement
filed-by/agent
filed-by/user
frozen
lint-rule
needs-info
needs-triage
next
plugin/cc-architect
plugin/os
plugin/os-adr
plugin/os-aidd-lint
plugin/os-backlog
plugin/os-context
plugin/os-doc-hygiene
plugin/os-sdlc
plugin/os-vault
project/cc-os
ready-for-agent
ready-for-human
recurring
review
rule-proposal
update
waiting
wayfinder:grilling
wayfinder:map
wayfinder:map
wayfinder:research
wayfinder:task
wayfinder:task
wontfix
worklist/deviations
worklist/lint-rule
worklist/new-implement-build
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
jared/cc-os#1464
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
OsSdlc::Implementation::WorkOrderis aData.define(:session_id, :ticket, :map_name, :target)inplugins/os-sdlc/lib/os_sdlc/implementation/work_order.rb.Its constructor requires session_id, ticket, and map_name; target defaults to nil.
73 test files outside support build it by hand, for example
plugins/os-sdlc/tests/implementation_complete_stamp_test.rb:14.Each copy is a Mystery Guest.
Approach
Add
plugins/os-sdlc/tests/support/work_order_fixture.rb:DEFAULTS holds only the three required fields, with the smallest valid values.
Migrate each call site that passes default-like values.
A site that passes a distinctive value keeps passing it as an override (rule 5).
Required work:
module WorkOrderFixtureinplugins/os-sdlc/tests/support/work_order_fixture.rbWorkOrder.new(session_id:inplugins/os-sdlc/tests/*.rbAcceptance criteria
plugins/os-sdlc/testsoutside support, whenWorkOrder.new(is counted, then the count is 0, or the only hits are in the class's own test.Owner sketch
Origin
VERDICT: CREATE
Parent: #1019
Work started on branch fast-batch-22.
Resolution
Done: WorkOrderFixture.build (DEFAULTS session-1/1/toy) replaces hand-built WorkOrder records in os-sdlc tests; overrides kept where a test relies on them; default-equal overrides dropped by ruling S5.
Evidence: fast-batch-22 merged to main
5f32ca8f; commitsa1b6fbba,c5d8aff3. WorkOrder.new outside support: 87 sites in 73 files -> 1 (work_order_test.rb). Full suite 2904 runs, 0 failures. Memo docs/crc/os-sdlc/fast-batch-22/finding-d-work-order-fixture.md.Follow-ups: none