Skip to content

Fix(testing): Register shutdown handler to delete temp input file#7800

Merged
TomasVotruba merged 0 commit intorectorphp:mainfrom
guanguans:main
Jan 5, 2026
Merged

Fix(testing): Register shutdown handler to delete temp input file#7800
TomasVotruba merged 0 commit intorectorphp:mainfrom
guanguans:main

Conversation

@guanguans
Copy link
Contributor

When using die, exit related debugging statements [dd(...)] to debug code in testing, the tearDown method will not be called, resulting in the inability to delete temporary input file.

  • Register shutdown function to delete the temporary input file via FileSystem::delete
  • Avoid leftover test artifacts by removing fixture-derived files on process exit

Loading
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.

3 participants