In Wikibase and WikibaseLexeme we are using TestCase::prophesize() from phpspec/prophecy. This used to come automatically with PHPUnit. However with PHPUnit patch release 8.5.29, its dependency phpspec/prophecy was dropped, breaking backward compatibility. This caused the UBN T315892: PHPUnit\Framework\Exception: This test uses TestCase::prophesize(), but phpspec/prophecy is not installed.. This was mitigated by pinning PHPUnit to 8.25.28 for now.
We need to figure out how to enable us to upgrade PHPUnit properly again.
Possible ways forward:
- adding phpspec/prophecy as a proper MediaWiki core require-dev composer dependency
- reworking our tests to no longer use that prophecy functionality
- ?
Acceptance Criteria:
- We are able to unpin and update PHPUnit to a version above 8.25.28 without causing CI breaks
Open Questions:
- Is this prophecy functionality actually good and maintainable and we want to use it, or is it something we would like to get rid of?