Problem/Motivation
Follow up to #3252257: Remove PHPUnit 8 support. The compatibility writer was moved but the code wasn't adjusted to take into account the new code location.
This leads to errors like this:
Warning: mkdir(): Permission denied in /app/core/tests/Drupal/TestTools/PhpUnitCompatibility/ClassWriter.php on line 108
PHP Warning: file_put_contents(/app/core/tests/Drupal/TestTools/PhpUnitCompatibility/../../../../../../sites/simpletest/Assert.php): Failed to open stream: No such file or directory in /app/core/tests/Drupal/TestTools/PhpUnitCompatibility/ClassWriter.php on line 110
...
Steps to reproduce
1. clone drupal
2. composer install
3. ./vendor/bin/phpunit -c core core/modules/system/tests/src/Functional/Common/RenderWebTest.php
Proposed resolution
Fix the code.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 3259158-2.patch | 787 bytes | neclimdul |
Comments
Comment #2
neclimdulThis is the root of the problem from the related issue's patch.
You can see why the move was a problem in the patch.
Not sure why this hasn't shown up in the last month other then maybe not many people aren't doing things in d10 or are used to running the upgrade scripts to avoid the rewrite or maybe just users generally have write access to the parent directory? Either way, simple fix.
Comment #3
longwaveYup, make sense to me. Locally I have a
sites/simpletestdirectory in the wrong location because of this.Comment #4
alexpottNice find @neclimdul
Committed 45d838f and pushed to 10.0.x. Thanks!