flysystem icon indicating copy to clipboard operation
flysystem copied to clipboard

PHPUnit v12.x support for FilesystemAdapterTestCase

Open aedart opened this issue 8 months ago • 0 comments

Feature Request

The FilesystemAdapterTestCase is compatible with PHPUnit ^9.5.11|^10.0 (according to the root composer.json). Furthermore, I can confirm that it also works with PHPUnit v11.x, via my own tests. However, the test-case is not compatible with PHPUnit version 12.x. The reason is that annotations (e.g. @test, @before, @after... etc.) are no longer supported in the latest version. They have been deprecated in version 11 (see metadata heading).

Attributes must be used instead.

Possible Solution

It is possible to use the provided Attributes from PHPUnit, and still keep the annotations. This will ensure that developers with older PHPUnit can still continue to function., whilst newer versions of PHPUnit are simply going to ignore the annotations and use the Attributes.

aedart avatar Apr 23 '25 14:04 aedart