You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I went to run a Behat test on a PR I had been working on previously (wp-cli/wp-cli/#5943) and it failed to run with a Directory not empty message:
Warning: rename(/var/folders/84/0kzx05wx0hx82cbpv99r052c0000gp/T/wp-cli-test-sqlite-integration-cache/sqlite-database-integration-2.1.3/,/var/folders/84/0kzx05wx0hx82cbpv99r052c0000gp/T/wp-cli-test-sqlite-integration-cache/sqlite-database-integration/): Directory not empty in /Users/brian.henry/Sites/wp-cli/wp-cli/vendor/wp-cli/wp-cli-tests/src/Context/FeatureContext.php line 372
Describe how other contributors can replicate this bug
I'm unsure.
I removed the directory at /var/folders/84/0kzx05wx0hx82cbpv99r052c0000gp/T/wp-cli-test-sqlite-integration-cache/sqlite-database-integration/ and the test ran successfully, and repeated runs of the same test did not result in the same issue.
I can't see how this happened. This line must have evaluated true:
Bug Report
Describe the current, buggy behavior
I went to run a Behat test on a PR I had been working on previously (wp-cli/wp-cli/#5943) and it failed to run with a Directory not empty message:
Describe how other contributors can replicate this bug
I'm unsure.
I removed the directory at
/var/folders/84/0kzx05wx0hx82cbpv99r052c0000gp/T/wp-cli-test-sqlite-integration-cache/sqlite-database-integration/
and the test ran successfully, and repeated runs of the same test did not result in the same issue.I can't see how this happened. This line must have evaluated true:
wp-cli-tests/src/Context/FeatureContext.php
Line 413 in 0c5c2e9
Describe what you would expect as the correct outcome
Tests should run.
Let us know what environment you are running this on
Also tested with PHP 7.4, thinking it was something stricter about 8.1 – same behaviour.
Provide a possible solution
Probably should just delete the destination directory before using it. It's a temp directory anyway.
Provide additional context/Screenshots
Repeatedly running the same tests three weeks ago was causing no problem.
The text was updated successfully, but these errors were encountered: