test: add job tests for BatchContentGeneration and ProcessContentTask #41
No reviewers
Labels
No labels
P1
P2
P3
PHP
agent-ready
bug
clotho
discovery
docs
refactor
review
security
testing
athena
athena-gemini
audit
clotho
clotho-gemini
codex
darbs-claude
security
wiki
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: core/php-agentic#41
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "test/job-tests"
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?
Summary
Closes #10
tests/Feature/Jobs/BatchContentGenerationTest.phpcovering job configuration, queue assignment, tag generation, and job chaining (dispatch ofProcessContentTaskper task)tests/Feature/Jobs/ProcessContentTaskTest.phpcovering all execution paths inhandle(), thefailed()handler, retry logic, variable interpolation, theprocessOutput()stub behaviour, and entitlement/workspace integrationTest coverage
BatchContentGenerationTest
ShouldQueueai-batchwithQueue::fake()batch-generation+priority:*for all priority values)ProcessContentTaskis dispatched per task on theaiqueueProcessContentTaskTest
tries = 3,backoff = 60,timeout = 300,ShouldQueuefailed(): marks task failed with the exact exception messagehandle()early exits: missing prompt, denied entitlement, unavailable providerhandle()success without workspace: no entitlement check, no usage recordinghandle()success with workspace: entitlement check +recordUsage()called with correct metadataprocessOutput()stub: no crash whether target is null or present (documents incomplete stub)input_datafailed()invoked on unhandled exceptionTest plan
./vendor/bin/pest --filter=Jobspasses in a host application withhost-uk/coreinstalledphp -l)🤖 Generated with Claude Code