Skip to content

Support for PHPUnit 11#47

Merged
jakzal merged 2 commits intojakzal:mainfrom
aaajeetee:main
May 20, 2024
Merged

Support for PHPUnit 11#47
jakzal merged 2 commits intojakzal:mainfrom
aaajeetee:main

Conversation

@aaajeetee
Copy link
Copy Markdown
Contributor

@aaajeetee aaajeetee commented May 8, 2024

I like this package very much and helps me setting up my test cases a lot better, so thanks for the work so far!

This package is bound to PHPUnit version 10 though, so I updated the composer dependency to also allow version 11.

I ran the tests and they succeeded (with PHPUnit version 11). I did also encounter some deprecated PHPUnit warnings, so I fixed them as well.

I am not sure if other code needs to be updated, but by the looks of it, and checking the PHPUnit documentation, I think the code is PHPUnit 11 compatible.

The deprecation warnings I got, that are now fixed:

There were 4 PHPUnit test runner deprecations:

1) Metadata found in doc-comment for method Zalas\PHPUnit\Globals\Tests\AnnotationExtensionTest::test_it_cleans_up_after_itself(). Metadata in doc-comments is deprecated and will no longer be supported in PHPUnit 12. Update your test code to use attributes instead.

2) Metadata found in doc-comment for method Zalas\PHPUnit\Globals\Tests\AttributeExtensionNoAttributesTest::test_it_cleans_up_after_itself(). Metadata in doc-comments is deprecated and will no longer be supported in PHPUnit 12. Update your test code to use attributes instead.

3) Metadata found in doc-comment for method Zalas\PHPUnit\Globals\Tests\AttributeExtensionTest::test_it_cleans_up_after_itself(). Metadata in doc-comments is deprecated and will no longer be supported in PHPUnit 12. Update your test code to use attributes instead.

4) Metadata found in doc-comment for method Zalas\PHPUnit\Globals\Tests\AttributeExtensionWithDataProviderTest::test_it_handles_dataproviders(). Metadata in doc-comments is deprecated and will no longer be supported in PHPUnit 12. Update your test code to use attributes instead.

@aaajeetee
Copy link
Copy Markdown
Contributor Author

@jakzal can you perhaps give an indication when this PR will be reviewed or merged? Would be very nice to use this package with the newest PHPUnit version 😁

@jakzal jakzal merged commit ba691ca into jakzal:main May 20, 2024
@jakzal
Copy link
Copy Markdown
Owner

jakzal commented May 20, 2024

Thank you @aaajeetee 🍺

@jakzal
Copy link
Copy Markdown
Owner

jakzal commented May 20, 2024

Unfortunately, I had to roll back as the build failed on creating a working phar. Can you resubmit, please?

The extension is stable, so if necessary it's perfectly fine to drop PHPUnit 10. PHPUnit 10 users can still use past releases, while we can move forward.

@jakzal jakzal mentioned this pull request May 20, 2024
@jakzal
Copy link
Copy Markdown
Owner

jakzal commented May 20, 2024

Ok, I got it working and brought back your changes. Thank you for your contribution @aaajeetee!

Released as v3.3.0.

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