Skip to content

Capture malformed PHPUnit bootstrap payloads#1933

Merged
chubes4 merged 2 commits into
mainfrom
fix/1916-malformed-bootstrap-diagnostics
Jul 21, 2026
Merged

Capture malformed PHPUnit bootstrap payloads#1933
chubes4 merged 2 commits into
mainfrom
fix/1916-malformed-bootstrap-diagnostics

Conversation

@chubes4

@chubes4 chubes4 commented Jul 21, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • execute generated PHPUnit PHP inside an outer diagnostic boundary
  • persist ParseError and other pre-handler throwables before rethrowing
  • retain the existing inner recorder for fatal and non-fatal bootstrap exits
  • prove malformed generated PHP in a real Playground runtime

Root cause

After #1932 captured exit()/die(), current Intelligence CI still produced no marker. That means the generated payload fails before its first shutdown callback can register. Directly submitted malformed PHP has the same behavior; wrapping evaluation lets WP Codebox persist the parse failure first.

Verification

  • npm run build
  • npm run test:phpunit-runtime-failure-diagnostics
  • npm run test:playground-phpunit-bootstrap-failure-integration
  • git diff --check

Fixes #1916

@chubes4
chubes4 merged commit 4e5874b into main Jul 21, 2026
4 checks passed
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.

Preserve diagnostics when wordpress.phpunit crashes in Playground

1 participant