Skip to content

Preserve existing PHPUnit configuration files - #2044

Merged
MrPunyapal merged 3 commits into
pestphp:5.xfrom
haranishi:fix/own-generated-configuration
Nov 19, 2026
Merged

MrPunyapal merged 3 commits into
pestphp:5.xfrom
haranishi:fix/own-generated-configuration

Conversation

@haranishi

Copy link
Copy Markdown
Contributor

What:

  • Bug Fix
  • New Feature

Description:

Pest can remove an existing .pest.xml after running with an explicit or discovered PHPUnit configuration. Two Pest runs in the same directory can also interfere when they both need a generated configuration.

Create the generated configuration exclusively and clean it up when the process that created it exits. Keep the regular configuration path for a run without contention so Test Impact Analysis can still reuse its fingerprint.

The regression tests cover existing project files, generated files, parallel workers, and a generated path that is replaced during the run.

composer test passed. Two concurrent CLI runs in the same fixture directory also held and removed their own configuration files. The ordinary and fallback paths both retained Test Impact Analysis replay on repeat runs. The shared success snapshot passed after regeneration with #2041, #2042, and #2043 applied together.

@MrPunyapal
MrPunyapal merged commit d65b04a into pestphp:5.x Nov 19, 2026
7 checks passed
@MrPunyapal

Copy link
Copy Markdown
Member

Thanks!

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.

2 participants